1 2 package junit.tests.runner; 3 4 import junit.framework.Test; 5 import junit.framework.TestCase; 6 import junit.runner.BaseTestRunner; 7 8 public class BaseTestRunnerTest extends TestCase { 9 10 public class MockRunner extends BaseTestRunner { 11 protected void runFailed(String message) { 12 } 13 14 public void testEnded(String testName) { 15 } 16 17 public void testFailed(int status, Test test, Throwable t) { 18 } 19 20 public void testStarted(String testName) { 21 } 22 } 23 24 public static class NonStatic { 25 public Test suite() { 26 return null; 27 } 28 } 29 30 31 public void testInvokeNonStaticSuite() { 32 BaseTestRunner runner= new MockRunner(); 33 runner.getTest("junit.tests.runner.BaseTestRunnerTest$NonStatic"); } 35 } 36 | Popular Tags |