Examples of TestRunner


Examples of com.arjuna.ats.tools.perftest.TestRunner

            ut = createTx();

            try
            {

                test(new TestRunner(), 1, 1);

                for (int i = 0; i < THRCOUNT.length; i++)
                {
                    for (int j = 0; j < TXCOUNT.length; j++)
                    {
                        TestRunner tr = test(new TestRunner(), THRCOUNT[i], TXCOUNT[j]);

                        writeResults(tr, TXCOUNT[j]);
//                        csv[i + 1][prodIndex + 2] = (float) tr.getAvg() / TXCOUNT[j];
                        csv[i + 1][prodIndex + 2] = TXCOUNT[j] * 1000 / tr.getAvg();
                    }
                }
            }
            catch (SQLException e)
            {
View Full Code Here

Examples of com.eviware.soapui.model.testsuite.TestRunner

      e1.printStackTrace();
    }
   
    TestSuite testSuite = project.getTestSuiteByName(getTestSuiteName());
     
    TestRunner runner = testSuite.run(new PropertiesMap(), false);
   
    assertEquals(Status.FINISHED, runner.getStatus());
   
  }
View Full Code Here

Examples of junit.textui.TestRunner

     * This is a quick and dirty program to run the MdcInjectionFilterTest many times.
     * To be removed once we consider DIRMINA-784 to be fixed
     *
     */
    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) {
            e.printStackTrace();
View Full Code Here

Examples of junit.textui.TestRunner

public class LoopTestJMagick {

  public static void main(String[] args) throws Throwable {
    TestSuite suite = new TestSuite();
    suite.addTestSuite(TestJMagick.class);
    TestRunner aTestRunner = new TestRunner();

    TestJMagick.popupWindow = false;
    MagickTesttools.dont_compare_output = true;

View Full Code Here

Examples of junit.textui.TestRunner

     * This is a quick and dirty program to run the MdcInjectionFilterTest many times.
     * To be removed once we consider DIRMINA-784 to be fixed
     *
     */
    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) {
            e.printStackTrace();
View Full Code Here

Examples of junit.textui.TestRunner

            fail("Shouldn't get here.");
        }
    }

    public void testSingle() throws Exception {
        TestRunner t = new TestRunner();
        t.setPrinter(new ResultPrinter(new PrintStream(new ByteArrayOutputStream())));
        String[] args = {
                "-m", "junit.tests.runner.TextRunnerSingleMethodTest$InvocationTest.testWasInvoked"
        };
        fgWasInvoked = false;
        t.start(args);
        assertTrue(fgWasInvoked);
    }
View Full Code Here

Examples of junit.textui.TestRunner

    }

    @Override
    public void setUp() {
        output = new ByteArrayOutputStream();
        runner = new TestRunner(new TestResultPrinter(new PrintStream(output)));
    }
View Full Code Here

Examples of junit.textui.TestRunner

        }
    }

    public void testError() {
        ByteArrayOutputStream output = new ByteArrayOutputStream();
        TestRunner runner = new TestRunner(new TestResultPrinter(
                new PrintStream(output)));

        String expected = expected(new String[]{".E", "Time: 0",
                "Errors here", "", "FAILURES!!!",
                "Tests run: 1,  Failures: 0,  Errors: 1", ""});
        ResultPrinter printer = new TestResultPrinter(new PrintStream(output)) {
            @Override
            public void printErrors(TestResult result) {
                getWriter().println("Errors here");
            }
        };
        runner.setPrinter(printer);
        TestSuite suite = new TestSuite();
        suite.addTest(new TestCase() {
            @Override
            public void runTest() throws Exception {
                throw new Exception();
            }
        });
        runner.doRun(suite);
        assertEquals(expected, output.toString());
    }
View Full Code Here

Examples of junit.textui.TestRunner

        }
    }

    public void testErrorAdapted() {
        ByteArrayOutputStream output = new ByteArrayOutputStream();
        TestRunner runner = new TestRunner(new TestResultPrinter(
                new PrintStream(output)));

        String expected = expected(new String[]{".E", "Time: 0",
                "Errors here", "", "FAILURES!!!",
                "Tests run: 1,  Failures: 0,  Errors: 1", ""});
        ResultPrinter printer = new TestResultPrinter(new PrintStream(output)) {
            @Override
            public void printErrors(TestResult result) {
                getWriter().println("Errors here");
            }
        };
        runner.setPrinter(printer);
        runner.doRun(new JUnit4TestAdapter(ATest.class));
        assertEquals(expected, output.toString());
    }
View Full Code Here

Examples of junit.textui.TestRunner

  }
 
  @Override
  public void setUp() {
    output= new ByteArrayOutputStream();
    runner= new TestRunner(new TestResultPrinter(new PrintStream(output)));
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.