public void CanBeConstructed_IsNotNull() { var options = new TreeRunnerOptions { Path = "." }; var runner = new RecursiveTreeRunner(options, 0); runner.ShouldNotBeNull(); runner.ShouldBeOfType <RecursiveTreeRunner>(); }
public void Run_MaxDepths_Runs(int maxDepth, int expectedDirectoryCount, int expectedFileCount) { string basePath = SetUpFolders(); var options = new TreeRunnerOptions { Path = basePath, MaxDepth = maxDepth }; var recursiveRunner = new RecursiveTreeRunner(options, 0); var result = recursiveRunner.Run(); result.ShouldNotBeNull(); result.DirectoryCount.ShouldBe(expectedDirectoryCount); result.FileCount.ShouldBe(expectedFileCount); }
public RecursiveTreeRunner(TreeRunnerOptions options, int level) { _options = options; _level = level; }
public TreeRunner(TreeRunnerOptions options) { _options = options; }