/// <summary> /// Explore a loaded TestPackage and return information about /// the tests found. /// </summary> /// <param name="filter">A TestFilter used to select tests</param> /// <returns>An XmlNode representing the tests found.</returns> public XmlNode Explore(TestFilter filter) { LoadResult = PrepareResult(_engineRunner.Explore(filter)) .Aggregate(TEST_RUN_ELEMENT, TestPackage.Name, TestPackage.FullName); return(LoadResult.Xml); }
/// <summary> /// Explore a loaded TestPackage and return information about /// the tests found. /// </summary> /// <param name="filter">A TestFilter used to select tests</param> /// <returns>An XmlNode representing the tests found.</returns> public XmlNode Explore(TestFilter filter) { LoadResult = PrepareResult(_engineRunner.Explore(filter)) .MakeTestRunResult(TestPackage); return(LoadResult.Xml); }
/// <summary> /// Explore a loaded TestPackage and return information about /// the tests found. /// </summary> /// <param name="filter">A TestFilter used to select tests</param> /// <returns>An XmlNode representing the tests found.</returns> public XmlNode Explore(TestFilter filter) { EnsurePackageIsLoaded(); // Needed? return(_engineRunner.Explore(filter) .Aggregate(TEST_RUN_ELEMENT, TestPackage.Name, TestPackage.FullName).Xml); }
/// <summary> /// Explore a loaded TestPackage and return information about /// the tests found. /// </summary> /// <param name="filter">Criteria used to filter the search results</param> /// <returns>A TestEngineResult.</returns> public TestEngineResult Explore(TestFilter filter) { if (_runner == null) { throw new InvalidOperationException("RemoteTestAgent: Explore called before Load"); } return(_runner.Explore(filter)); }
private void CommandLoop() { bool keepRunning = true; var socketReader = new SocketReader(_clientSocket, new BinarySerializationProtocol()); while (keepRunning) { var command = socketReader.GetNextMessage <CommandMessage>(); switch (command.CommandName) { case "CreateRunner": var package = (TestPackage)command.Arguments[0]; _runner = CreateRunner(package); break; case "Load": SendResult(_runner.Load()); break; case "Reload": SendResult(_runner.Reload()); break; case "Unload": _runner.Unload(); break; case "Explore": var filter = (TestFilter)command.Arguments[0]; SendResult(_runner.Explore(filter)); break; case "CountTestCases": filter = (TestFilter)command.Arguments[0]; SendResult(_runner.CountTestCases(filter)); break; case "Run": filter = (TestFilter)command.Arguments[0]; SendResult(_runner.Run(this, filter)); break; case "RunAsync": filter = (TestFilter)command.Arguments[0]; _runner.RunAsync(this, filter); break; case "Stop": keepRunning = false; break; } } Stop(); }
/// <summary> /// Explore a TestPackage and return information about /// the tests found. /// </summary> /// <param name="filter">A TestFilter used to select tests</param> /// <returns>A TestEngineResult.</returns> protected override TestEngineResult ExploreTests(TestFilter filter) { try { return(_remoteRunner.Explore(filter)); } catch (Exception e) { log.Error("Failed to run remote tests {0}", e.Message); return(CreateFailedResult(e)); } }
/// <summary> /// Explore a TestPackage and return information about /// the tests found. /// </summary> /// <param name="filter">A TestFilter used to select tests</param> /// <returns>A TestEngineResult.</returns> public override TestEngineResult Explore(TestFilter filter) { try { CreateAgentAndRunner(); return(_remoteRunner.Explore(filter)); } catch (Exception e) { log.Error("Failed to run remote tests {0}", ExceptionHelper.BuildMessageAndStackTrace(e)); return(CreateFailedResult(e)); } }
/// <summary> /// Explore a TestPackage and return information about /// the tests found. /// </summary> /// <param name="filter">A TestFilter used to select tests</param> /// <returns>A TestEngineResult.</returns> protected override TestEngineResult ExploreTests(TestFilter filter) { return(_remoteRunner.Explore(filter)); }
/// <summary> /// Explore a loaded TestPackage and return information about /// the tests found. /// </summary> /// <param name="filter">A TestFilter used to select tests</param> /// <returns>A TestEngineResult.</returns> protected override TestEngineResult ExploreTests(TestFilter filter) { return(_realRunner.Explore(filter).Aggregate(TEST_RUN_ELEMENT, TestPackage.Name, TestPackage.FullName)); }
/// <summary> /// Explore a loaded TestPackage and return information about /// the tests found. /// </summary> /// <param name="filter">Criteria used to filter the search results</param> /// <returns>A TestEngineResult.</returns> public TestEngineResult Explore(TestFilter filter) { return(_runner.Explore(filter)); }
/// <summary> /// Explore a loaded TestPackage and return information about /// the tests found. /// </summary> /// <param name="package">The TestPackage to be explored</param> /// <returns>A TestEngineResult.</returns> public TestEngineResult Explore(TestFilter filter) { return(runner == null ? null : runner.Explore(filter)); }
/// <summary> /// Explore a loaded TestPackage and return information about /// the tests found. /// </summary> /// <param name="filter">A TestFilter used to select tests</param> /// <returns>An XmlNode representing the tests found.</returns> public XmlNode Explore(TestFilter filter) { return(_engineRunner.Explore(filter) .Aggregate(TEST_RUN_ELEMENT, TestPackage.Name, TestPackage.FullName).Xml); }