throws DependencyTreeBuilderException
{
MockControl control = MockControl.createStrictControl( DependencyNodeVisitor.class );
DependencyNodeVisitor visitor = (DependencyNodeVisitor) control.getMock();
DependencyNode springContext =
new DependencyNode( createArtifact( "org.springframework", "spring-context", "2.5.6" ) );
springContext.setPremanagedVersion( "2.5.5" );
DependencyNode springTest =
new DependencyNode( createArtifact( "org.springframework", "spring-test", "2.5.5", "test" ) );
DependencyNode plexusUtils =
new DependencyNode( createArtifact( "org.codehaus.plexus", "plexus-utils", "1.4.5" ) );
plexusUtils.setPremanagedVersion( "1.5.1" );
DependencyNode slf4jLog4j12 =
new DependencyNode( createArtifact( "org.slf4j", "slf4j-log4j12", "1.5.0", "runtime" ) );
slf4jLog4j12.setPremanagedScope( "test" );
DependencyNode plexusLog4j = new DependencyNode(
createArtifact( "org.codehaus.plexus", "plexus-log4j-logging", "1.1-alpha-3", "test" ) );
DependencyNode log4j = new DependencyNode( createArtifact( "log4j", "log4j", "1.2.14", "test" ) );
DependencyNode mavenArtifact =
new DependencyNode( createArtifact( "org.apache.maven", "maven-artifact", "2.0.8", "test" ) );
DependencyNode mavenProject =
new DependencyNode( createArtifact( "org.apache.maven", "maven-project", "2.0.8", "test" ) );
DependencyNode mavenCore =
new DependencyNode( createArtifact( "org.apache.maven", "maven-core", "2.0.8", "test" ) );
DependencyNode mavenSettings =
new DependencyNode( createArtifact( "org.apache.maven", "maven-settings", "2.0.8", "test" ) );
DependencyNode mavenModel =
new DependencyNode( createArtifact( "org.apache.maven", "maven-model", "2.0.8", "test" ) );
DependencyNode plexusCommandLine =
new DependencyNode( createArtifact( "org.codehaus.plexus", "plexus-command-line", "1.0-alpha-2", "test" ) );
DependencyNode plexusRegistryCommons = new DependencyNode(
createArtifact( "org.codehaus.plexus.registry", "plexus-registry-commons", "1.0-alpha-2", "test" ) );
plexusRegistryCommons.setPremanagedVersion( "1.0-alpha-3" );
DependencyNode plexusRegistryApi = new DependencyNode(
createArtifact( "org.codehaus.plexus.registry", "plexus-registry-api", "1.0-alpha-2", "test" ) );
plexusRegistryApi.setPremanagedVersion( "1.0-alpha-3" );
DependencyNode plexusSpring =
new DependencyNode( createArtifact( "org.codehaus.plexus", "plexus-spring", "1.2", "test" ) );
plexusSpring.addChild( springContext );
plexusSpring.addChild( springTest );
plexusSpring.addChild( plexusUtils );
plexusSpring.addChild( slf4jLog4j12 );
plexusSpring.addChild( plexusLog4j );
plexusSpring.addChild( log4j );
plexusSpring.addChild( mavenArtifact );
plexusSpring.addChild( mavenProject );
plexusSpring.addChild( mavenCore );
plexusSpring.addChild( mavenSettings );
plexusSpring.addChild( mavenModel );
plexusSpring.addChild( plexusCommandLine );
plexusSpring.addChild( plexusRegistryCommons );
plexusSpring.addChild( plexusRegistryApi );
DependencyNode commonsLang = new DependencyNode( createArtifact( "commons-lang", "commons-lang", "2.2" ) );
DependencyNode commonsIO = new DependencyNode( createArtifact( "commons-io", "commons-io", "1.4" ) );
DependencyNode slf4j = new DependencyNode( createArtifact( "org.slf4j", "slf4j-api", "1.5.0" ) );
DependencyNode plexusAPI =
new DependencyNode( createArtifact( "org.codehaus.plexus", "plexus-component-api", "1.0-alpha-22" ) );
DependencyNode xalan = new DependencyNode( createArtifact( "xalan", "xalan", "2.7.0" ) );
DependencyNode dom4j = new DependencyNode( createArtifact( "dom4j", "dom4j", "1.6.1", "test" ) );
dom4j.setFailedUpdateScope( "compile" );
DependencyNode junit = new DependencyNode( createArtifact( "junit", "junit", "3.8.1", "test" ) );
DependencyNode easymock = new DependencyNode( createArtifact( "easymock", "easymock", "1.2_Java1.3", "test" ) );
DependencyNode easymockExt =
new DependencyNode( createArtifact( "easymock", "easymockclassextension", "1.2", "test" ) );
DependencyNode mainNode =
new DependencyNode( createProjectArtifact( TEST_GROUP_ID, TEST_ARTIFACT_ID, TEST_VERSION ) );
mainNode.addChild( commonsLang );
mainNode.addChild( commonsIO );
mainNode.addChild( slf4j );
mainNode.addChild( plexusAPI );
mainNode.addChild( plexusSpring );
mainNode.addChild( xalan );
mainNode.addChild( dom4j );
mainNode.addChild( junit );
mainNode.addChild( easymock );
mainNode.addChild( easymockExt );
control.expectAndReturn( visitor.visit( mainNode ), true );
control.expectAndReturn( visitor.visit( commonsLang ), true );
control.expectAndReturn( visitor.endVisit( commonsLang ), true );