public void FindFiles() { TestFileContext.CreateFiles("folder/foo/test.txt", "folder/foo/sub/test3.txt", "folder/foo/sub/test.txt", "folder/bar/sub/example2.json"); var results = File.Find(new FindInput() { Directory = TestFileContext.RootPath, Pattern = "**/*.xml" }, new FindOption()); Assert.Equal(2, results.Count); Assert.True(results.All(x => x.Extension.Equals(".xml"))); }
public UnitTest() { TestFileContext.CreateFiles( "folder/foo/sub/test.xml", "folder/bar/sub/example.xml"); }