use of io.jenkins.blueocean.rest.model.BlueTrend in project blueocean-plugin by jenkinsci.
the class BlueTrendTest method testTrendsIdCollision.
@Test
public void testTrendsIdCollision() throws Exception {
// verify the extension did register correctly
ExtensionList<BlueTrendFactory> extensionList = ExtensionList.lookup(BlueTrendFactory.class);
Assert.assertEquals(2, extensionList.size());
Project project = j.createProject(FreeStyleProject.class, "freestyle1");
BlueOrganization org = new OrganizationImpl("jenkins", j.jenkins);
BluePipeline pipeline = new AbstractPipelineImpl(org, project);
BlueTrendContainer trends = pipeline.getTrends();
BlueTrend trend = trends.get("junit");
Assert.assertEquals("junit", trend.getId());
Assert.assertEquals("JUnit", trend.getDisplayName());
}
Aggregations