private void ProcessTest(Test test) { TestResult result = TestResult.Pass; if (test.CompleteReason == TestCompleteReason.Finished) { if (logging_server.IsTestResultSet(test.InputFileName)) { result = logging_server.GetTestResult(test.InputFileName); if (result == TestResult.Fail) { test.SetFailedReason("Test LogResult set to FAIL"); } } if (result == TestResult.Pass) { result = test.ComputeImageCompareResult(); } } else { test.SetFailedReason(String.Format("Test did not complete properly ({0})", test.CompleteReason)); result = TestResult.Fail; } if (result == TestResult.Pass && test.UnitTest) { result = test.ProcessUnitTestResult(); } if (test.IsKnownFailure) { result = (result == TestResult.Pass) ? TestResult.UnexpectedPass : TestResult.KnownFailure; } RecordResult(test, result); reports.ForEach(delegate(IReport report) { report.AddResult(test, result); }); test.Teardown(); }
private void ProcessTest (Test test) { TestResult result = TestResult.Pass; if (test.CompleteReason == TestCompleteReason.Finished) { if (logging_server.IsTestResultSet (test.InputFileName)) { result = logging_server.GetTestResult (test.InputFileName); if (result == TestResult.Fail) test.SetFailedReason ("Test LogResult set to FAIL"); } if (result == TestResult.Pass) result = test.ComputeImageCompareResult (); } else { test.SetFailedReason (String.Format ("Test did not complete properly ({0})", test.CompleteReason)); result = TestResult.Fail; } if (result == TestResult.Pass && test.UnitTest) result = test.ProcessUnitTestResult (); if (test.IsKnownFailure) result = (result == TestResult.Pass) ? TestResult.UnexpectedPass : TestResult.KnownFailure; RecordResult (test, result); reports.ForEach (delegate (IReport report) { report.AddResult (test, result); }); test.Teardown (); }