public void TestFalseCustomMessageWithContext() { var verifier = new NUnitVerifier().PushContext("Known Context"); var exception = Assert.Throws <AssertionException>(() => verifier.False(true, "Custom message")); verifier.EqualOrDiff($" Context: Known Context{Environment.NewLine}Custom message{Environment.NewLine} Expected: False{Environment.NewLine} But was: True{Environment.NewLine}", exception.Message); }
public void TestFalseMessage() { var verifier = new NUnitVerifier(); var exception = Assert.Throws <AssertionException>(() => verifier.False(true)); verifier.EqualOrDiff($" Expected: False{Environment.NewLine} But was: True{Environment.NewLine}", exception.Message); }