throws Exception
{
CompilerMojo compileMojo =
getCompilerMojo( "target/test-classes/unit/compiler-one-output-file-test2/plugin-config.xml" );
setVariableValueToObject( compileMojo, "compilerManager", new CompilerManagerStub() );
Set includes = new HashSet();
includes.add( "**/TestCompile4*.java" );
setVariableValueToObject( compileMojo, "includes", includes );
Set excludes = new HashSet();
excludes.add( "**/TestCompile2*.java" );
excludes.add( "**/TestCompile3*.java" );
setVariableValueToObject( compileMojo, "excludes", excludes );
compileMojo.execute();
File testClass = new File( compileMojo.getOutputDirectory(), "compiled.class" );
assertTrue( testClass.exists() );
TestCompilerMojo testCompileMojo = getTestCompilerMojo( compileMojo,
"target/test-classes/unit/compiler-one-output-file-test2/plugin-config.xml" );
setVariableValueToObject( testCompileMojo, "compilerManager", new CompilerManagerStub() );
setVariableValueToObject( testCompileMojo, "testIncludes", includes );
setVariableValueToObject( testCompileMojo, "testExcludes", excludes );
testCompileMojo.execute();