Package junit.framework

Examples of junit.framework.JUnit4TestAdapter


    public static void main(String[] args) {
        TestRunner runner = new TestRunner();

        try {
            for (int i=0; i<50000; i++) {
                Test test = new JUnit4TestAdapter(MdcInjectionFilterTest.class);
                runner.doRun(test);
                System.out.println("i = " + i + " " + new Date());
            }
            System.out.println("done");
        } catch (Exception e) {
View Full Code Here


{
    // Check the LARQ examples at least run without problems.
   
    public static junit.framework.Test suite()
    {
        return new JUnit4TestAdapter(TestLARQExamples.class) ;
    }
View Full Code Here

        } catch (Throwable e) {
            return new BrokenTest(
                    Description.createSuiteDescription(String.format("initializationError(%s)", testClassName)), e);
        }

        return new JUnit4TestAdapter(testClass);
    }
View Full Code Here

   * Support JUnit3 as well
   *
   * @return the Test for JUnit3 to function properly.
   */
  public static junit.framework.Test suite() {
    return new JUnit4TestAdapter(AllTests.class);
  }
View Full Code Here

   * Support JUnit3 as well
   *
   * @return the Test for JUnit3 to function properly.
   */
  public static junit.framework.Test suite() {
    return new JUnit4TestAdapter(AllTests.class);
  }
View Full Code Here

    public static void main(String[] args) {
        TestRunner runner = new TestRunner();

        try {
            for (int i=0; i<50000; i++) {
                Test test = new JUnit4TestAdapter(MdcInjectionFilterTest.class);
                runner.doRun(test);
                System.out.println("i = " + i + " " + new Date());
            }
            System.out.println("done");
        } catch (Exception e) {
View Full Code Here

        assertEquals(2, runner.testCount());
    }

    @Test
    public void ensureSuitesWorkWithForwardCompatibility() {
        junit.framework.Test test = new JUnit4TestAdapter(All.class);
        TestResult result = new TestResult();
        test.run(result);
        assertEquals(2, result.runCount());
    }
View Full Code Here

        assertEquals(2, result.runCount());
    }

    @Test
    public void forwardCompatibilityWorksWithGetTests() {
        JUnit4TestAdapter adapter = new JUnit4TestAdapter(All.class);
        List<? extends junit.framework.Test> tests = adapter.getTests();
        assertEquals(2, tests.size());
    }
View Full Code Here

        assertEquals(2, tests.size());
    }

    @Test
    public void forwardCompatibilityWorksWithTestCount() {
        JUnit4TestAdapter adapter = new JUnit4TestAdapter(All.class);
        assertEquals(2, adapter.countTestCases());
    }
View Full Code Here

    }

    @Test
    public void compatibility() {
        TestResult result = new TestResult();
        new JUnit4TestAdapter(IgnoredTest.class).run(result);
        assertEquals(1, result.runCount());
    }
View Full Code Here

TOP

Related Classes of junit.framework.JUnit4TestAdapter

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.