Examples of TestSetFailedException


Examples of org.apache.maven.surefire.testset.TestSetFailedException

    static Concurrency resolveConcurrency( JUnitCoreParameters params ) throws TestSetFailedException
    {
        if ( !params.isAnyParallelitySelected() )
        {
            throw new TestSetFailedException( "Unspecified parameter '" + JUnitCoreParameters.PARALLEL_KEY + "'." );
        }

        if ( !params.isUseUnlimitedThreads() && !hasThreadCount( params ) && !hasThreadCounts( params ) )
        {
            throw new TestSetFailedException( "Unspecified thread-count(s). " +
                    "See the parameters " + JUnitCoreParameters.USEUNLIMITEDTHREADS_KEY + ", "
                    + JUnitCoreParameters.THREADCOUNT_KEY + ", " + JUnitCoreParameters.THREADCOUNTSUITES_KEY + ", "
                    + JUnitCoreParameters.THREADCOUNTCLASSES_KEY + ", " + JUnitCoreParameters.THREADCOUNTMETHODS_KEY + ".");
        }
View Full Code Here

Examples of org.apache.maven.surefire.testset.TestSetFailedException

        {
            testObject = testClass.newInstance();
        }
        catch ( InstantiationException e )
        {
            throw new TestSetFailedException( "Unable to instantiate POJO '" + testClass + "'", e );
        }
        catch ( IllegalAccessException e )
        {
            throw new TestSetFailedException( "Unable to instantiate POJO '" + testClass + "'", e );
        }
    }
View Full Code Here

Examples of org.apache.maven.surefire.testset.TestSetFailedException

    }

    public void execute( String testSetName, ReporterFactory reporterManagerFactory )
        throws TestSetFailedException
    {
        throw new TestSetFailedException( "Cannot run individual test when suite files are specified" );
    }
View Full Code Here

Examples of org.apache.maven.surefire.testset.TestSetFailedException

        for ( Object suiteFile : suiteFiles )
        {
            File file = (File) suiteFile;
            if ( !file.exists() || !file.isFile() )
            {
                throw new TestSetFailedException( "Suite file " + file + " is not a valid file" );
            }
            this.testSets.put( file, file.getAbsolutePath() );
            this.suiteFilePaths.add( file.getAbsolutePath() );
        }
View Full Code Here

Examples of org.apache.maven.surefire.testset.TestSetFailedException

                {
                    reason.append( "   " );
                    reason.append( testClass.getName() );
                    reason.append( "\n" );
                }
                throw new TestSetFailedException( reason.toString() );
            }
        }
    }
View Full Code Here

Examples of org.apache.maven.surefire.testset.TestSetFailedException

        {
            return Class.forName( className );
        }
        catch ( Exception ex )
        {
            throw new TestSetFailedException( "Cannot find listener class " + className, ex );
        }
    }
View Full Code Here

Examples of org.apache.maven.surefire.testset.TestSetFailedException

    static Concurrency resolveConcurrency( JUnitCoreParameters params, RunnerCounter counts )
        throws TestSetFailedException
    {
        if ( !params.isParallelismSelected() )
        {
            throw new TestSetFailedException( "Unspecified parameter '" + JUnitCoreParameters.PARALLEL_KEY + "'." );
        }

        if ( !params.isUseUnlimitedThreads() && !hasThreadCount( params ) && !hasThreadCounts( params ) )
        {
            throw new TestSetFailedException( "Unspecified thread-count(s). " +
                                                  "See the parameters " + JUnitCoreParameters.USEUNLIMITEDTHREADS_KEY
                                                  + ", " + JUnitCoreParameters.THREADCOUNT_KEY + ", "
                                                  + JUnitCoreParameters.THREADCOUNTSUITES_KEY + ", "
                                                  + JUnitCoreParameters.THREADCOUNTCLASSES_KEY + ", "
                                                  + JUnitCoreParameters.THREADCOUNTMETHODS_KEY + "." );
View Full Code Here

Examples of org.apache.maven.surefire.testset.TestSetFailedException

                }
                return executedTests;
            }
            catch ( Exception e )
            {
                throw new TestSetFailedException( e );
            }
        }
        return Collections.emptySet();
    }
View Full Code Here

Examples of org.apache.maven.surefire.testset.TestSetFailedException

            Method method = clazz.getMethod( "setMethodName", new Class[] { String.class } );
            method.invoke( null, methodNamePattern );
        }
        catch ( ClassNotFoundException e )
        {
            throw new TestSetFailedException( e.getMessage(), e );
        }
        catch ( SecurityException e )
        {
            throw new TestSetFailedException( e.getMessage(), e );
        }
        catch ( NoSuchMethodException e )
        {
            throw new TestSetFailedException( e.getMessage(), e );
        }
        catch ( IllegalArgumentException e )
        {
            throw new TestSetFailedException( e.getMessage(), e );
        }
        catch ( IllegalAccessException e )
        {
            throw new TestSetFailedException( e.getMessage(), e );
        }
        catch ( InvocationTargetException e )
        {
            throw new TestSetFailedException( e.getMessage(), e );
        }

        XmlMethodSelector xms = new XmlMethodSelector();

        xms.setName( clazzName );
View Full Code Here

Examples of org.apache.maven.surefire.testset.TestSetFailedException

        if ( computer instanceof ParallelComputer )
        {
            String timeoutMessage = ( (ParallelComputer) computer ).describeElapsedTimeout();
            if ( timeoutMessage.length() != 0 )
            {
                throw new TestSetFailedException( timeoutMessage );
            }
        }
    }
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.