Skip to content

Commit

Permalink
throw exception and do not surpress
Browse files Browse the repository at this point in the history
  • Loading branch information
mmanela committed Sep 2, 2016
1 parent d5174a5 commit 0c7e1a9
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion Chutzpah/Callbacks/RunnerCallback.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,17 @@ namespace Chutzpah
public abstract class RunnerCallback : ITestMethodRunnerCallback
{
public static ITestMethodRunnerCallback Empty = new EmptyRunnerCallback();
private sealed class EmptyRunnerCallback : RunnerCallback { }
private sealed class EmptyRunnerCallback : RunnerCallback
{
public override void ExceptionThrown(Exception exception, string fileName)
{
// Default runner callback will re-throw exception. In other implementations
// we don't do this since we know they can report the error
base.ExceptionThrown(exception, fileName);

throw exception;
}
}

public virtual void TestSuiteStarted() { }
public virtual void TestSuiteFinished(TestCaseSummary testResultsSummary) { }
Expand Down

0 comments on commit 0c7e1a9

Please sign in to comment.