Examples of RcovBuildAction


Examples of hudson.plugins.rubyMetrics.rcov.RcovBuildAction

public class RcovFileResultTest {
    @Test
    public void testLoadOldBuildXml() throws Exception {
        FreeStyleBuild build = (FreeStyleBuild)Run.XSTREAM2.fromXML(this.getClass().getResourceAsStream("build.xml"));
        assertNotNull("Build was null", build);
        RcovBuildAction action = build.getAction(RcovBuildAction.class);
        assertNotNull("Build action was null", action);
        RcovFileResult result = action.getResults().getFiles().iterator().next();
        Field sourceCode = RcovFileResult.class.getDeclaredField("sourceCode");
        sourceCode.setAccessible(true);
        assertNull(sourceCode.get(result));
    }
View Full Code Here

Examples of hudson.plugins.rubyMetrics.rcov.RcovBuildAction

        // Run and wait for the build; assert success
        FreeStyleBuild build = j.assertBuildStatusSuccess(project.scheduleBuild2(0));

        // Assert that the build has an rcov build action attached
        RcovBuildAction action = build.getAction(RcovBuildAction.class);
        assertNotNull("Missing RcovBuildAction for build " + build, action);

        // Check each detail object to see that it can load its source code
        for (RcovFileResult result: action.getResults().getFiles()) {
            RcovFileDetail detail = new RcovFileDetail(build, result);
            String sourceCode = detail.loadSourceCode();
            assertNotNull("Missing source code for file " + result.getName(), sourceCode);
            assertThat("Missing table tag in source code for file " + result.getName(), sourceCode, containsString("<table"));
        }
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.