Package hudson.plugins.disk_usage

Examples of hudson.plugins.disk_usage.DiskUsageProperty$DiskUsageDescriptor


    public void testOnDeleted() throws Exception{
        AbstractProject project = j.createFreeStyleProject();
        j.buildAndAssertSuccess(project);
        j.buildAndAssertSuccess(project);
        j.buildAndAssertSuccess(project);
        DiskUsageProperty property = (DiskUsageProperty) project.getProperty(DiskUsageProperty.class);
        project.getBuildByNumber(2).delete();
        assertNull("Build 2 was not removed from caches informations.", property.getDiskUsageBuildInformation(2));
        assertNotNull("Disk usage property whoud contains cashed information about build 1.", property.getDiskUsageOfBuild(1));
        assertNotNull("Disk usage property whoud contains cashed information about build 3.", property.getDiskUsageOfBuild(3));
    }
View Full Code Here


    @Test
    public void testOnCompleted() throws Exception{
        FreeStyleProject project = j.createFreeStyleProject();
        project.getBuildersList().add(new Shell("echo ahoj > log.log"));
        j.buildAndAssertSuccess(project);
        DiskUsageProperty property = (DiskUsageProperty) project.getProperty(DiskUsageProperty.class);
        assertNotNull("Build information is cached.", property.getDiskUsageBuildInformation(1));
        assertTrue("Build disk usage should be counted.", property.getDiskUsageOfBuild(1)>0);
        assertTrue("Workspace of build should be counted.", property.getAllWorkspaceSize()>0);
    }
View Full Code Here

   
    @Test
    @LocalData
    public void testLoadingAllBuildInformationFromPreviousVersion(){
       AbstractProject project = (AbstractProject) j.jenkins.getItem("project1");
       DiskUsageProperty property = (DiskUsageProperty) project.getProperty(DiskUsageProperty.class);   
       assertEquals("Builds information should be loaded.", 8, property.getDiskUsageOfBuilds().size(), 0);
    }
View Full Code Here

TOP

Related Classes of hudson.plugins.disk_usage.DiskUsageProperty$DiskUsageDescriptor

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.