Example #1
0
        public void GetFiles1_All()
        {
            FilesOperator filesOperator = new FilesOperator(directory);
            string[] filesFromMask = filesOperator.GetFiles(false, false);

            Assert.IsTrue(CollectionUtil<string>.HaveSameElements(new List<string>(files), new List<string>(filesFromMask)));
        }
Example #2
0
        public void GetFiles2_OneFile_LowercaseExtension()
        {
            FilesOperator filesOperator = new FilesOperator(directory, "*.txt");
            string[] filesFromMask = filesOperator.GetFiles(false, false);

            List<string> expectedFiles = new List<string>();
            expectedFiles.Add("Text File.txt");

            Assert.IsTrue(CollectionUtil<string>.HaveSameElements(expectedFiles, new List<string>(filesFromMask)));
        }