private void Report() { reportBuilder = new StringBuilder(); reportBuilder.AppendLine(); Verifying = false; Shrinking = false; Reporting = true; Failed = false; var failingSpec = FailingSpec; var exception = Exception; foreach (var run in Runs.ToList()) { RunNumber = run; Runner(this); } Failed = true; FailingSpec = failingSpec; Exception = exception; if (Exception != null) { throw new FalsifiableException(reportBuilder.ToString(), exception); } throw new FalsifiableException(reportBuilder.ToString()); }
private void ShrinkActions() { Verifying = true; Shrinking = false; Reporting = false; BreakRun = false; Failed = false; var failingSpec = FailingSpec; var exception = Exception; var max = Runs.Max(); var current = 0; while (current <= max) { Failed = false; TempMemory = new TempMemory(); FailingSpec = failingSpec; Exception = exception; foreach (var run in Runs.ToList()) { RunNumber = run; if (run != current) { Runner(this); } if (BreakRun) { break; } } if (Failed && !BreakRun) { Runs.Remove(current); } current++; } Failed = true; FailingSpec = failingSpec; Exception = exception; }
private void ShrinkInputs() { Verifying = false; Shrinking = true; Reporting = false; Failed = false; TempMemory = new TempMemory(); var failingSpec = FailingSpec; var exception = Exception; foreach (var run in Runs.ToList()) { RunNumber = run; Runner(this); } Failed = true; FailingSpec = failingSpec; Exception = exception; }