public void CapturedErrorHasCodeTest() { var ce = new CapturedError(); ce.ErrorCode("Level-1", "Cap", 12); Assert.IsTrue(ce.HasCode("Level-1", "Cap")); }
public void CapturedErrorHasCodeWithNoParametersTest() { var ce = new CapturedError(); ce.ErrorCode("Level-1", "Cap", 12); Assert.IsTrue(ce.HasCode()); }
public void CapturedErrorHasCodeSoughtTooLongTest() { var ce = new CapturedError(); ce.ErrorCode("Level-1", "Cap", 12); Assert.IsFalse(ce.HasCode("Level-1", "Cap", 12, "List")); }
public void CapturedErrorHasCodeMismatchTest() { var ce = new CapturedError(); ce.ErrorCode("Level-1", "Cap", 12); Assert.IsFalse(ce.HasCode("Level-1", "Flip")); }
public void CapturedErrorSetMessageAndCodeTest() { var ce = new CapturedError(); ce.ErrorMessage("It's too late").ErrorCode("Level-1", "Cap", 12); Assert.IsTrue(ce.Message == "It's too late"); Assert.IsTrue(ce.HasCode("Level-1", "Cap", 12)); }