public void LoadTests(IList <string> files) { if (IsPackageLoaded) { UnloadTests(); } _files = files; TestsLoading?.Invoke(new TestFilesLoadingEventArgs(files)); _package = MakeTestPackage(files); Runner = _testEngine.GetRunner(_package); Tests = new TestNode(Runner.Explore(TestFilter.Empty)); Categories = CategoryExplorer.Expolre(Tests); _resultIndex.Clear(); TestLoaded?.Invoke(new TestNodeEventArgs(TestAction.TestLoaded, Tests, Categories)); foreach (var subPackage in _package.SubPackages) { RecentFiles.SetMostRecent(subPackage.FullName); } }
public void ReloadTests() { Runner.Unload(); _resultIndex.Clear(); Tests = null; _package = MakeTestPackage(_files); Runner = _testEngine.GetRunner(_package); Tests = new TestNode(Runner.Explore(TestFilter.Empty)); Categories = CategoryExplorer.Expolre(Tests); _resultIndex.Clear(); TestReloaded?.Invoke(new TestNodeEventArgs(TestAction.TestReloaded, Tests, Categories)); }