Package hudson.matrix

Examples of hudson.matrix.MatrixRun$RunnerImpl


     * Unmarshall a matrix build.xml result.
     */
    @Bug(10903)
    public void testUnMarshalRunMatrix() {
        InputStream is = XStream2Test.class.getResourceAsStream("runMatrix.xml");
        MatrixRun result = (MatrixRun) Run.XSTREAM.fromXML(is);
        assertNotNull(result);
        assertNotNull(result.getPersistentActions());
        assertEquals(2, result.getPersistentActions().size());
        InterruptedBuildAction action = (InterruptedBuildAction) result.getPersistentActions().get(1);
        assertNotNull(action.getCauses());
        assertEquals(1, action.getCauses().size());
        CauseOfInterruption.UserInterruption cause =
            (CauseOfInterruption.UserInterruption) action.getCauses().get(0);
        assertNotNull(cause);
View Full Code Here


        XStream xStream = new XStream2();
        xStream.registerConverter(new TriggerContextConverter());
        xStream.alias("matrix-run", MatrixRun.class);
        Object obj = xStream.fromXML(getClass().getResourceAsStream("matrix_build.xml"));
        assertTrue(obj instanceof MatrixRun);
        MatrixRun run = (MatrixRun)obj;

        Cause.UpstreamCause upCause = run.getCause(Cause.UpstreamCause.class);
        List upstreamCauses = Whitebox.getInternalState(upCause, "upstreamCauses");
        GerritCause cause = (GerritCause)upstreamCauses.get(0);
        assertNotNull(cause.getEvent());
        assertThat("Event is not a ChangeBasedEvent", cause.getEvent(), instanceOf(ChangeBasedEvent.class));
        ChangeBasedEvent changeBasedEvent = (ChangeBasedEvent)cause.getEvent();
View Full Code Here

TOP

Related Classes of hudson.matrix.MatrixRun$RunnerImpl

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.