示例#1
0
        public void TestGetPathsCount()
        {
            //arrange
            createFakeDirectory();
            string directory = @"Fakes\";
            int    pathCount;
            int    expectedPathCount = 1;

            Paths.filetypes filetype = Paths.filetypes.txt;

            //act
            pathCount = Paths.GetPathsCount(directory, filetype);

            //assert
            Assert.AreEqual(expectedPathCount, pathCount);
        }
示例#2
0
        public void TestGetAllPaths()
        {
            //arrange
            createFakeDirectory();
            string        directory     = @"Fakes\";
            List <string> paths         = new List <string>();
            List <string> expectedPaths = new List <string>();

            Paths.filetypes filetype = Paths.filetypes.txt;
            expectedPaths.Add(@"Fakes\Test.txt");

            //act
            paths = Paths.GetAllPaths(directory, filetype);

            //assert
            CollectionAssert.AreEqual(expectedPaths, paths);
        }