Esempio n. 1
0
        public void GetEntries_WithAbsolutePath_Works()
        {
            var target = new FileSystemItem().SetName("target");

            new FileSystemItem().SetChildren(new[]
            {
                target,
                new FileSystemItem().SetName("sibling").SetChildren(
                    "nephew1",
                    "nephew2"
                    )
            });

            var result = target.GetEntries("/sibling").ToArray();

            Assert.AreEqual(2, result.Length);
            Assert.Contains("/sibling/nephew1", result);
            Assert.Contains("/sibling/nephew2", result);
        }