throws Exception
{
File testPom = new File( getBasedir(), "target/test-classes/unit/tree-test/plugin-config.xml" );
String outputFileName = testDir.getAbsolutePath() + outputFile;
TreeMojo mojo = (TreeMojo) lookupMojo( "tree", testPom );
setVariableValueToObject( mojo, "localRepository", new StubArtifactRepository( testDir.getAbsolutePath() ) );
setVariableValueToObject( mojo, "outputType", format );
setVariableValueToObject( mojo, "outputFile", new File( outputFileName ) );
assertNotNull( mojo );
assertNotNull( mojo.getProject() );