private CodeQuality makeSecurityAnalysis() { CodeQuality quality = new CodeQuality(); quality.setId(ObjectId.get()); quality.setCollectorItemId(ObjectId.get()); quality.setTimestamp(1); quality.setName("MyFortify"); quality.setType(CodeQualityType.SecurityAnalysis); quality.setUrl("http://mycompany.fortify.ssc.com/MyFortify"); quality.setVersion("dev"); quality.getMetrics().add(makeMetric()); return quality; }
private CodeQuality makeCodeQualityStatic() { CodeQuality quality = new CodeQuality(); quality.setId(ObjectId.get()); quality.setCollectorItemId(ObjectId.get()); quality.setTimestamp(1); quality.setName("MyTest"); quality.setType(CodeQualityType.StaticAnalysis); quality.setUrl("http://mycompany.sonar.com/MyTest"); quality.setVersion("1.0.0.1"); quality.getMetrics().add(makeMetric()); return quality; }