Esempio n. 1
0
        public void DiscoverObsoleteProjectFileWorks()
        {
            var fileSystem = new FileSystemMock();

            fileSystem
            .AddDirectory(@"d:\foo")
            .AddFile(@"bar.txt", "some text content")
            .Parent.AddDirectory(@"bar");

            Assert.IsFalse(fileSystem.GetFileInfoSnapshot(new FullPath(@"d:\foo\bar2")).Exists);
            Assert.IsTrue(fileSystem.GetFileInfoSnapshot(new FullPath(@"d:\foo\bar")).IsDirectory);
            Assert.IsTrue(fileSystem.GetFileInfoSnapshot(new FullPath(@"d:\foo\bar.txt")).IsFile);
        }