Package org.jenkinsci.plugins.workflow.cps.nodes

Examples of org.jenkinsci.plugins.workflow.cps.nodes.StepAtomNode


    private void shouldHaveWatchSteps(Class<? extends StepDescriptor> d, int n) {
        int count=0;
        for (Row row : t.getRows()) {
            if (row.getNode() instanceof StepAtomNode) {
                StepAtomNode a = (StepAtomNode)row.getNode();
                if (a.getDescriptor().getClass()==d)
                    count++;
            }
        }
        assertEquals(n,count);
    }
View Full Code Here


        // TODO: generalize the notion of Step taking over the FlowNode creation.
        // see https://trello.com/c/v6Pbwqxj/13-allowing-steps-to-build-flownodes
        boolean hack = d instanceof ParallelStep.DescriptorImpl;

        if (ps.body == null && !hack) {
            an = new StepAtomNode(exec, d, thread.head.get());
            // TODO: use CPS call stack to obtain the current call site source location. See JENKINS-23013
            thread.head.setNewHead(an);
        } else {
            an = new StepStartNode(exec, d, thread.head.get());
            thread.head.setNewHead(an);
View Full Code Here

        // we expect every shell step to have failed
        FlowGraphTable t = new FlowGraphTable(b.getExecution());
        t.build();
        for (Row r : t.getRows()) {
            if (r.getNode() instanceof StepAtomNode) {
                StepAtomNode a = (StepAtomNode) r.getNode();
                if (a.getDescriptor().getClass()==ShellStep.DescriptorImpl.class) {
                    assertTrue(a.getAction(ErrorAction.class)!=null);
                }
            }
        }
    }
View Full Code Here

        boolean found = false;
        FlowGraphTable t = new FlowGraphTable(b.getExecution());
        t.build();
        for (Row r : t.getRows()) {
            if (r.getNode() instanceof StepAtomNode) {
                StepAtomNode sa = (StepAtomNode) r.getNode();
                if (sa.getDescriptor().getFunctionName().equals("sh")) {
                    assertSame(BallColor.RED, sa.getIconColor());
                    found = true;
                }
            }
        }
View Full Code Here

TOP

Related Classes of org.jenkinsci.plugins.workflow.cps.nodes.StepAtomNode

Copyright © 2018 www.massapicom. 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.