Package org.apache.maven.surefire.common.junit4

Examples of org.apache.maven.surefire.common.junit4.JUnit4ProviderUtilTest$T2


    public void test_publicT1SSIMap()
    {
        testMethod( "publicT1SSIMap", new T1(), DSVersion.DS10, null );
        testMethod( "publicT1SSIMap", new T1(), DSVersion.DS11, "publicT1SSIMap" );
        testMethod( "publicT1SSIMap", new T2(), DSVersion.DS10, null );
        testMethod( "publicT1SSIMap", new T2(), DSVersion.DS11, "publicT1SSIMap" );
    }
View Full Code Here


        // T1 should use its own public implementation
        testMethod( "suitable", new T1(), DSVersion.DS10, "suitableT1" );
        testMethod( "suitable", new T1(), DSVersion.DS11, "suitableT1" );

        // T2's private implementation is only visible for DS 1.1
        testMethod( "suitable", new T2(), DSVersion.DS10, null );
        testMethod( "suitable", new T2(), DSVersion.DS11, "suitableT2" );

        // T3 extends T2 and cannot see T2's private method
        testMethod( "suitable", new T3(), DSVersion.DS10, null );
        testMethod( "suitable", new T3(), DSVersion.DS11, null );
View Full Code Here

    private static final Class[] EMPTY_CLASS_ARRAY = new Class[0];

    @Test
    public void testGetAnnotatedIgnore()
    {
        JUnit4Reflector reflector = new JUnit4Reflector();
        final Method testSomething2 =
            ReflectionUtils.getMethod( IgnoreWithDescription.class, "testSomething2", EMPTY_CLASS_ARRAY );
        final Annotation[] annotations = testSomething2.getAnnotations();
        Description desc =
            Description.createTestDescription( IgnoreWithDescription.class, "testSomething2", annotations );
        Ignore annotatedIgnore = reflector.getAnnotatedIgnore( desc );
        Assert.assertEquals( reason, annotatedIgnore.value() );
    }
View Full Code Here

        final RunListener reporter = reporterFactory.createReporter();

        ConsoleOutputCapture.startCapture( (ConsoleOutputReceiver) reporter );

        JUnit4RunListener jUnit4TestSetReporter = new JUnit4RunListener( reporter );

        Result result = new Result();
        RunNotifier runNotifer = getRunNotifer( jUnit4TestSetReporter, result, customRunListeners );

        runNotifer.fireTestRunStarted( null );
View Full Code Here

        final RunListener reporter = reporterFactory.createReporter();

        ConsoleOutputCapture.startCapture( (ConsoleOutputReceiver) reporter );

        JUnit4RunListener jUnit4TestSetReporter = new JUnit4RunListener( reporter );

        Result result = new Result();
        RunNotifier runNotifer = getRunNotifer( jUnit4TestSetReporter, result, customRunListeners );

        runNotifer.fireTestRunStarted( null );
View Full Code Here

        RunListener reporter = reporterFactory.createReporter();

        ConsoleOutputCapture.startCapture( (ConsoleOutputReceiver) reporter );

        JUnit4RunListener jUnit4TestSetReporter = new JUnit4RunListener( reporter );

        Result result = new Result();
        RunNotifier runNotifier = getRunNotifier( jUnit4TestSetReporter, result, customRunListeners );

        runNotifier.fireTestRunStarted( createTestsDescription() );
View Full Code Here

        final RunListener reporter = reporterFactory.createReporter();

        ConsoleOutputCapture.startCapture( (ConsoleOutputReceiver) reporter );

        JUnit4RunListener jUnit4TestSetReporter = new JUnit4RunListener( reporter );

        Result result = new Result();
        RunNotifier runNotifer = getRunNotifer( jUnit4TestSetReporter, result, customRunListeners );

        runNotifer.fireTestRunStarted( null );
View Full Code Here

        // e.g. org.junit.Test, but no classes from other packages,
        // in particular org.junit.runner.RunWith can't be loaded
        Set<String> visiblePackages = Collections.singleton( "org.junit" );
        PackageFilteringClassLoader filteringTestClassloader =
            new PackageFilteringClassLoader( testClassLoader, visiblePackages );
        JUnit4TestChecker checker = new JUnit4TestChecker( filteringTestClassloader );
        assertTrue( checker.accept( testClass ) );
    }
View Full Code Here

    private final JUnit4TestChecker jUnit4TestChecker;


    public JUnit48TestChecker( ClassLoader testClassLoader )
    {
        this.jUnit4TestChecker = new JUnit4TestChecker( testClassLoader );
        this.nonAbstractClassFilter = new NonAbstractClassFilter();
    }
View Full Code Here

        this.testClassLoader = booterParameters.getTestClassLoader();
        this.scanResult = booterParameters.getScanResult();
        this.runOrderCalculator = booterParameters.getRunOrderCalculator();
        customRunListeners = JUnit4RunListenerFactory.
            createCustomListeners( booterParameters.getProviderProperties().getProperty( "listener" ) );
        jUnit4TestChecker = new JUnit4TestChecker( testClassLoader );
        requestedTestMethod = booterParameters.getTestRequest().getRequestedTestMethod();

    }
View Full Code Here

TOP

Related Classes of org.apache.maven.surefire.common.junit4.JUnit4ProviderUtilTest$T2

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.