Package org.apache.maven.archiva.dependency.graph.tasks

Examples of org.apache.maven.archiva.dependency.graph.tasks.DependencyManagementStack.pop()


        dep.setScope( "test" );
        node.addDependencyManagement( dep );

        DependencyManagementStack stack = new DependencyManagementStack();
        stack.push( node );
        DependencyGraphNode oldnode = stack.pop();
        assertEquals( "added node to old node", node, oldnode );
    }

    public void testPushPopTwoDeep()
    {
View Full Code Here


        dep = toDependency( "junit:junit:3.7::jar" );
        transNode.addDependencyManagement( dep );
        stack.push( transNode );

        // Test it
        assertEquals( "popped node is trans node", transNode, stack.pop() );
        assertEquals( "popped node is direct node", directNode, stack.pop() );
        assertEquals( "popped node is project node", projectNode, stack.pop() );
    }

    public void testApplyNodeVersionParentWins()
View Full Code Here

        transNode.addDependencyManagement( dep );
        stack.push( transNode );

        // Test it
        assertEquals( "popped node is trans node", transNode, stack.pop() );
        assertEquals( "popped node is direct node", directNode, stack.pop() );
        assertEquals( "popped node is project node", projectNode, stack.pop() );
    }

    public void testApplyNodeVersionParentWins()
    {
View Full Code Here

        stack.push( transNode );

        // Test it
        assertEquals( "popped node is trans node", transNode, stack.pop() );
        assertEquals( "popped node is direct node", directNode, stack.pop() );
        assertEquals( "popped node is project node", projectNode, stack.pop() );
    }

    public void testApplyNodeVersionParentWins()
    {
        DependencyManagementStack stack = new DependencyManagementStack();
View Full Code Here

        // Test it
        DependencyGraphNode junitNode = toNode( "junit:junit:1.0::jar" );

        assertRules( "junit (lvl:trans)", stack, junitNode, "3.8.1", "test", null );
        stack.pop();
        assertRules( "junit (lvl:direct)", stack, junitNode, "3.8.1", "test", null );
        stack.pop();
        assertRules( "junit (lvl:project)", stack, junitNode, "3.8.1", "test", null );
    }
View Full Code Here

        DependencyGraphNode junitNode = toNode( "junit:junit:1.0::jar" );

        assertRules( "junit (lvl:trans)", stack, junitNode, "3.8.1", "test", null );
        stack.pop();
        assertRules( "junit (lvl:direct)", stack, junitNode, "3.8.1", "test", null );
        stack.pop();
        assertRules( "junit (lvl:project)", stack, junitNode, "3.8.1", "test", null );
    }

    /**
     * This test is based off of Carlos Sanchez's depman example use case.
View Full Code Here

        // Not added to the stack, as this is the node that is having the rules applied to it.
        DependencyGraphNode nodeD = toNode( "org.apache.maven.archiva:carlos-D:1.0::jar" );

        // Test it
        assertRules( "node D (lvl:C)", stack, nodeD, "2.0", null, null );
        stack.pop();
        assertRules( "node D (lvl:B)", stack, nodeD, "2.0", null, null );
        stack.pop();
        assertNoRules( "node D (lvl:A)", stack, nodeD, "2.0", null, null );
    }
View Full Code Here

        // Test it
        assertRules( "node D (lvl:C)", stack, nodeD, "2.0", null, null );
        stack.pop();
        assertRules( "node D (lvl:B)", stack, nodeD, "2.0", null, null );
        stack.pop();
        assertNoRules( "node D (lvl:A)", stack, nodeD, "2.0", null, null );
    }

    /**
     * Test for expected rules, that should be enforced for the provided node.
View Full Code Here

        dep.setScope( "test" );
        node.addDependencyManagement( dep );

        DependencyManagementStack stack = new DependencyManagementStack();
        stack.push( node );
        DependencyGraphNode oldnode = stack.pop();
        assertEquals( "added node to old node", node, oldnode );
    }

    public void testPushPopTwoDeep()
    {
View Full Code Here

        dep = toDependency( "junit:junit:3.7::jar" );
        transNode.addDependencyManagement( dep );
        stack.push( transNode );

        // Test it
        assertEquals( "popped node is trans node", transNode, stack.pop() );
        assertEquals( "popped node is direct node", directNode, stack.pop() );
        assertEquals( "popped node is project node", projectNode, stack.pop() );
    }

    public void testApplyNodeVersionParentWins()
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.