Esempio n. 1
0
 public void TestFailedSetUp()
 {
     test = new BrokenSetUp("");
     test.Run(result);
     if (result.Summary().StartsWith("SetUp is Failed:"))
     {
         return;
     }
     throw new AssertException();
 }
Esempio n. 2
0
 public void TestFailedResult()
 {
     test = new WasRun("TestBrokenMethod");
     test.Run(result);
     if ("1 run, 1 failed" == result.Summary())
     {
         return;
     }
     throw new AssertException();
 }
Esempio n. 3
0
 public void TestTearDownWhenTestFailed()
 {
     test = new WasRun("TestBrokenMethod");
     test.Run(result);
     if (test.Log.Contains("TearDown"))
     {
         return;
     }
     throw new AssertException();
 }
Esempio n. 4
0
 public void TestTemplateMethod()
 {
     test = new WasRun("TestMethod");
     test.Run(result);
     if ("SetUp TestMethod TearDown" == test.Log)
     {
         return;
     }
     throw new AssertException();
 }
Esempio n. 5
0
 public void TestIsNotRanTestMethodWhenSetUpIsFailed()
 {
     test = new BrokenSetUp("TestMethod");
     test.Run(result);
     if (!test.Log.Contains("TestMethod"))
     {
         return;
     }
     throw new AssertException();
 }