import static org.sonar.api.measures.Metric.ValueType.DATA;
import static org.sonar.api.measures.Metric.ValueType.DISTRIB;
import static org.sonar.api.utils.Paging.offset;
-import static org.sonar.core.util.Uuids.UUID_EXAMPLE_02;
import static org.sonar.db.component.ComponentTreeQuery.Strategy.CHILDREN;
import static org.sonar.db.component.ComponentTreeQuery.Strategy.LEAVES;
-import static org.sonar.server.component.ComponentFinder.ParamNames.BASE_COMPONENT_ID_AND_KEY;
import static org.sonar.server.component.ws.MeasuresWsParameters.ACTION_COMPONENT_TREE;
import static org.sonar.server.component.ws.MeasuresWsParameters.ADDITIONAL_METRICS;
import static org.sonar.server.component.ws.MeasuresWsParameters.ADDITIONAL_PERIOD;
import static org.sonar.server.component.ws.MeasuresWsParameters.DEPRECATED_ADDITIONAL_PERIODS;
-import static org.sonar.server.component.ws.MeasuresWsParameters.DEPRECATED_PARAM_BASE_COMPONENT_ID;
-import static org.sonar.server.component.ws.MeasuresWsParameters.DEPRECATED_PARAM_BASE_COMPONENT_KEY;
import static org.sonar.server.component.ws.MeasuresWsParameters.PARAM_ADDITIONAL_FIELDS;
import static org.sonar.server.component.ws.MeasuresWsParameters.PARAM_BRANCH;
import static org.sonar.server.component.ws.MeasuresWsParameters.PARAM_COMPONENT;
import static org.sonar.server.ws.KeyExamples.KEY_BRANCH_EXAMPLE_001;
import static org.sonar.server.ws.KeyExamples.KEY_PROJECT_EXAMPLE_001;
import static org.sonar.server.ws.KeyExamples.KEY_PULL_REQUEST_EXAMPLE_001;
-import static org.sonar.server.ws.WsParameterBuilder.createQualifiersParameter;
import static org.sonar.server.ws.WsParameterBuilder.QualifierParameterContext.newQualifierParameterContext;
+import static org.sonar.server.ws.WsParameterBuilder.createQualifiersParameter;
import static org.sonar.server.ws.WsUtils.writeProtobuf;
/**
private final ResourceTypes resourceTypes;
public ComponentTreeAction(DbClient dbClient, ComponentFinder componentFinder, UserSession userSession, I18n i18n,
- ResourceTypes resourceTypes) {
+ ResourceTypes resourceTypes) {
this.dbClient = dbClient;
this.componentFinder = componentFinder;
this.userSession = userSession;
@Override
public void define(WebService.NewController context) {
WebService.NewAction action = context.createAction(ACTION_COMPONENT_TREE)
- .setDescription(format("Navigate through components based on the chosen strategy with specified measures. The %s or the %s parameter must be provided.<br>" +
+ .setDescription(format("Navigate through components based on the chosen strategy with specified measures.<br>" +
"Requires the following permission: 'Browse' on the specified project.<br>" +
- "When limiting search with the %s parameter, directories are not returned.",
- DEPRECATED_PARAM_BASE_COMPONENT_ID, PARAM_COMPONENT, Param.TEXT_QUERY))
+ "When limiting search with the %s parameter, directories are not returned.", Param.TEXT_QUERY))
.setResponseExample(getClass().getResource("component_tree-example.json"))
.setSince("5.4")
.setHandler(this)
.addPagingParams(100, MAX_SIZE)
.setChangelog(
+ new Change("8.8", "parameter 'component' is now required"),
+ new Change("8.8", "deprecated parameter 'baseComponentId' has been removed"),
+ new Change("8.8", "deprecated parameter 'baseComponentKey' has been removed."),
+ new Change("8.8", "deprecated response field 'id' has been removed"),
+ new Change("8.8", "deprecated response field 'refId' has been removed."),
new Change("8.1", "the response field periods under measures field is deprecated. Use period instead."),
new Change("8.1", "the response field periods is deprecated. Use period instead."),
new Change("7.6", format("The use of module keys in parameter '%s' is deprecated", PARAM_COMPONENT)),
new Change("7.2", "field 'bestValue' is added to the response"),
new Change("6.3", format("Number of metric keys is limited to %s", MAX_METRIC_KEYS)),
- new Change("6.6", "the response field id is deprecated. Use key instead."),
- new Change("6.6", "the response field refId is deprecated. Use refKey instead."));
+ new Change("6.6", "the response field 'id' is deprecated. Use 'key' instead."),
+ new Change("6.6", "the response field 'refId' is deprecated. Use 'refKey' instead."));
action.createSortParams(SORTS, NAME_SORT, true)
.setDescription("Comma-separated list of sort fields")
.setMinimumLength(QUERY_MINIMUM_LENGTH)
.setExampleValue("FILE_NAM");
- action.createParam(DEPRECATED_PARAM_BASE_COMPONENT_ID)
- .setDescription("Base component id. The search is based on this component.")
- .setExampleValue(UUID_EXAMPLE_02)
- .setDeprecatedSince("6.6");
-
action.createParam(PARAM_COMPONENT)
+ .setRequired(true)
.setDescription("Component key. The search is based on this component.")
- .setExampleValue(KEY_PROJECT_EXAMPLE_001)
- .setDeprecatedKey(DEPRECATED_PARAM_BASE_COMPONENT_KEY, "6.6");
+ .setExampleValue(KEY_PROJECT_EXAMPLE_001);
action.createParam(PARAM_BRANCH)
.setDescription("Branch key. Not available in the community edition.")
List<String> metricKeys = request.mandatoryParamAsStrings(PARAM_METRIC_KEYS);
checkArgument(metricKeys.size() <= MAX_METRIC_KEYS, "Number of metrics keys is limited to %s, got %s", MAX_METRIC_KEYS, metricKeys.size());
ComponentTreeRequest componentTreeRequest = new ComponentTreeRequest()
- .setBaseComponentId(request.param(DEPRECATED_PARAM_BASE_COMPONENT_ID))
- .setComponent(request.param(PARAM_COMPONENT))
+ .setComponent(request.mandatoryParam(PARAM_COMPONENT))
.setBranch(request.param(PARAM_BRANCH))
.setPullRequest(request.param(PARAM_PULL_REQUEST))
.setMetricKeys(metricKeys)
}
private static Measures.Component.Builder toWsComponent(ComponentDto component, Map<MetricDto, ComponentTreeData.Measure> measures,
- Map<String, ComponentDto> referenceComponentsByUuid) {
+ Map<String, ComponentDto> referenceComponentsByUuid) {
Measures.Component.Builder wsComponent = componentDtoToWsComponent(component);
ComponentDto referenceComponent = referenceComponentsByUuid.get(component.getCopyResourceUuid());
if (referenceComponent != null) {
- wsComponent.setRefId(referenceComponent.uuid());
wsComponent.setRefKey(referenceComponent.getKey());
}
Measures.Measure.Builder measureBuilder = Measures.Measure.newBuilder();
}
private ComponentDto loadComponent(DbSession dbSession, ComponentTreeRequest request) {
- String componentId = request.getBaseComponentId();
String componentKey = request.getComponent();
String branch = request.getBranch();
String pullRequest = request.getPullRequest();
- checkArgument(componentId == null || (branch == null && pullRequest == null), "Parameter '%s' cannot be used at the same time as '%s' or '%s'",
- DEPRECATED_PARAM_BASE_COMPONENT_ID, PARAM_BRANCH, PARAM_PULL_REQUEST);
if (branch == null && pullRequest == null) {
- return componentFinder.getByUuidOrKey(dbSession, componentId, componentKey, BASE_COMPONENT_ID_AND_KEY);
+ return componentFinder.getByKey(dbSession, componentKey);
}
- checkRequest(componentKey != null, "The '%s' parameter is missing", PARAM_COMPONENT);
return componentFinder.getByKeyAndOptionalBranchOrPullRequest(dbSession, componentKey, branch, pullRequest);
}
}
private Table<String, MetricDto, ComponentTreeData.Measure> searchMeasuresByComponentUuidAndMetric(DbSession dbSession, ComponentDto baseComponent,
- ComponentTreeQuery componentTreeQuery, List<ComponentDto> components, List<MetricDto> metrics) {
+ ComponentTreeQuery componentTreeQuery, List<ComponentDto> components, List<MetricDto> metrics) {
Map<String, MetricDto> metricsByUuid = Maps.uniqueIndex(metrics, MetricDto::getUuid);
MeasureTreeQuery measureQuery = MeasureTreeQuery.builder()
* </ul>
*/
private static void addBestValuesToMeasures(Table<String, MetricDto, ComponentTreeData.Measure> measuresByComponentUuidAndMetric, List<ComponentDto> components,
- List<MetricDto> metrics) {
+ List<MetricDto> metrics) {
List<MetricDtoWithBestValue> metricDtosWithBestValueMeasure = metrics.stream()
.filter(MetricDtoFunctions.isOptimizedForBestValue())
.map(new MetricDtoToMetricDtoWithBestValue())
}
private static List<ComponentDto> filterComponents(List<ComponentDto> components,
- Table<String, MetricDto, ComponentTreeData.Measure> measuresByComponentUuidAndMetric, List<MetricDto> metrics, ComponentTreeRequest wsRequest) {
+ Table<String, MetricDto, ComponentTreeData.Measure> measuresByComponentUuidAndMetric, List<MetricDto> metrics, ComponentTreeRequest wsRequest) {
if (!componentWithMeasuresOnly(wsRequest)) {
return components;
}
}
private static List<ComponentDto> sortComponents(List<ComponentDto> components, ComponentTreeRequest wsRequest, List<MetricDto> metrics,
- Table<String, MetricDto, ComponentTreeData.Measure> measuresByComponentUuidAndMetric) {
+ Table<String, MetricDto, ComponentTreeData.Measure> measuresByComponentUuidAndMetric) {
return ComponentTreeSort.sortComponents(components, wsRequest, metrics, measuresByComponentUuidAndMetric);
}
import static org.sonar.db.component.SnapshotTesting.newAnalysis;
import static org.sonar.server.component.ws.MeasuresWsParameters.ADDITIONAL_PERIOD;
import static org.sonar.server.component.ws.MeasuresWsParameters.DEPRECATED_ADDITIONAL_PERIODS;
-import static org.sonar.server.component.ws.MeasuresWsParameters.DEPRECATED_PARAM_BASE_COMPONENT_ID;
-import static org.sonar.server.component.ws.MeasuresWsParameters.DEPRECATED_PARAM_BASE_COMPONENT_KEY;
import static org.sonar.server.component.ws.MeasuresWsParameters.PARAM_ADDITIONAL_FIELDS;
import static org.sonar.server.component.ws.MeasuresWsParameters.PARAM_BRANCH;
import static org.sonar.server.component.ws.MeasuresWsParameters.PARAM_COMPONENT;
public void load_measures_multi_sort_with_metric_key_and_paginated() {
ComponentDto project = db.components().insertPrivateProject();
SnapshotDto projectSnapshot = db.components().insertSnapshot(project);
- ComponentDto file9 = db.components().insertComponent(newFileDto(project, null, "file-uuid-9").setName("file-1"));
- ComponentDto file8 = db.components().insertComponent(newFileDto(project, null, "file-uuid-8").setName("file-1"));
- ComponentDto file7 = db.components().insertComponent(newFileDto(project, null, "file-uuid-7").setName("file-1"));
- ComponentDto file6 = db.components().insertComponent(newFileDto(project, null, "file-uuid-6").setName("file-1"));
- ComponentDto file5 = db.components().insertComponent(newFileDto(project, null, "file-uuid-5").setName("file-1"));
- ComponentDto file4 = db.components().insertComponent(newFileDto(project, null, "file-uuid-4").setName("file-1"));
- ComponentDto file3 = db.components().insertComponent(newFileDto(project, null, "file-uuid-3").setName("file-1"));
- ComponentDto file2 = db.components().insertComponent(newFileDto(project, null, "file-uuid-2").setName("file-1"));
- ComponentDto file1 = db.components().insertComponent(newFileDto(project, null, "file-uuid-1").setName("file-1"));
+ ComponentDto file9 = db.components().insertComponent(newFileDto(project, null, "file-uuid-9").setName("file-1").setDbKey("file-9-key"));
+ ComponentDto file8 = db.components().insertComponent(newFileDto(project, null, "file-uuid-8").setName("file-1").setDbKey("file-8-key"));
+ ComponentDto file7 = db.components().insertComponent(newFileDto(project, null, "file-uuid-7").setName("file-1").setDbKey("file-7-key"));
+ ComponentDto file6 = db.components().insertComponent(newFileDto(project, null, "file-uuid-6").setName("file-1").setDbKey("file-6-key"));
+ ComponentDto file5 = db.components().insertComponent(newFileDto(project, null, "file-uuid-5").setName("file-1").setDbKey("file-5-key"));
+ ComponentDto file4 = db.components().insertComponent(newFileDto(project, null, "file-uuid-4").setName("file-1").setDbKey("file-4-key"));
+ ComponentDto file3 = db.components().insertComponent(newFileDto(project, null, "file-uuid-3").setName("file-1").setDbKey("file-3-key"));
+ ComponentDto file2 = db.components().insertComponent(newFileDto(project, null, "file-uuid-2").setName("file-1").setDbKey("file-2-key"));
+ ComponentDto file1 = db.components().insertComponent(newFileDto(project, null, "file-uuid-1").setName("file-1").setDbKey("file-1-key"));
MetricDto coverage = insertCoverageMetric();
db.commit();
db.measures().insertLiveMeasure(file1, coverage, m -> m.setValue(1.0d));
.setParam(Param.PAGE_SIZE, "3")
.executeProtobuf(ComponentTreeWsResponse.class);
- assertThat(response.getComponentsList()).extracting("id").containsExactly("file-uuid-4", "file-uuid-5", "file-uuid-6");
+ assertThat(response.getComponentsList()).extracting("key").containsExactly("file-4-key", "file-5-key", "file-6-key");
assertThat(response.getPaging().getPageIndex()).isEqualTo(2);
assertThat(response.getPaging().getPageSize()).isEqualTo(3);
assertThat(response.getPaging().getTotal()).isEqualTo(9);
public void sort_by_metric_value() {
ComponentDto project = db.components().insertPrivateProject();
SnapshotDto projectSnapshot = db.components().insertSnapshot(project);
- ComponentDto file4 = db.components().insertComponent(newFileDto(project, null, "file-uuid-4"));
- ComponentDto file3 = db.components().insertComponent(newFileDto(project, null, "file-uuid-3"));
- ComponentDto file1 = db.components().insertComponent(newFileDto(project, null, "file-uuid-1"));
- ComponentDto file2 = db.components().insertComponent(newFileDto(project, null, "file-uuid-2"));
+ ComponentDto file4 = db.components().insertComponent(newFileDto(project, null, "file-uuid-4").setDbKey("file-4-key"));
+ ComponentDto file3 = db.components().insertComponent(newFileDto(project, null, "file-uuid-3").setDbKey("file-3-key"));
+ ComponentDto file1 = db.components().insertComponent(newFileDto(project, null, "file-uuid-1").setDbKey("file-1-key"));
+ ComponentDto file2 = db.components().insertComponent(newFileDto(project, null, "file-uuid-2").setDbKey("file-2-key"));
MetricDto ncloc = newMetricDto().setKey("ncloc").setValueType(INT.name()).setDirection(1);
dbClient.metricDao().insert(dbSession, ncloc);
db.commit();
.setParam(PARAM_METRIC_KEYS, "ncloc")
.executeProtobuf(ComponentTreeWsResponse.class);
- assertThat(response.getComponentsList()).extracting("id").containsExactly("file-uuid-1", "file-uuid-2", "file-uuid-3", "file-uuid-4");
+ assertThat(response.getComponentsList()).extracting("key").containsExactly("file-1-key", "file-2-key", "file-3-key", "file-4-key");
assertThat(response.getPaging().getTotal()).isEqualTo(4);
}
public void remove_components_without_measure_on_the_metric_sort() {
ComponentDto project = db.components().insertPrivateProject();
SnapshotDto projectSnapshot = db.components().insertSnapshot(project);
- ComponentDto file1 = newFileDto(project, null, "file-uuid-1");
- ComponentDto file2 = newFileDto(project, null, "file-uuid-2");
- ComponentDto file3 = newFileDto(project, null, "file-uuid-3");
- ComponentDto file4 = newFileDto(project, null, "file-uuid-4");
+ ComponentDto file1 = newFileDto(project, null, "file-uuid-1").setDbKey("file-1-key");
+ ComponentDto file2 = newFileDto(project, null, "file-uuid-2").setDbKey("file-2-key");
+ ComponentDto file3 = newFileDto(project, null, "file-uuid-3").setDbKey("file-3-key");
+ ComponentDto file4 = newFileDto(project, null, "file-uuid-4").setDbKey("file-4-key");
db.components().insertComponent(file1);
db.components().insertComponent(file2);
db.components().insertComponent(file3);
.setParam(PARAM_METRIC_SORT_FILTER, WITH_MEASURES_ONLY_METRIC_SORT_FILTER)
.executeProtobuf(ComponentTreeWsResponse.class);
- assertThat(response.getComponentsList()).extracting("id")
- .containsExactly(file1.uuid(), file2.uuid(), file3.uuid())
- .doesNotContain(file4.uuid());
+ assertThat(response.getComponentsList()).extracting("key")
+ .containsExactly(file1.getKey(), file2.getKey(), file3.getKey())
+ .doesNotContain(file4.getKey());
assertThat(response.getPaging().getTotal()).isEqualTo(3);
}
public void sort_by_metric_period() {
ComponentDto project = db.components().insertPrivateProject();
SnapshotDto projectSnapshot = db.components().insertSnapshot(project);
- ComponentDto file3 = db.components().insertComponent(newFileDto(project, null, "file-uuid-3"));
- ComponentDto file1 = db.components().insertComponent(newFileDto(project, null, "file-uuid-1"));
- ComponentDto file2 = db.components().insertComponent(newFileDto(project, null, "file-uuid-2"));
+ ComponentDto file3 = db.components().insertComponent(newFileDto(project, null, "file-uuid-3").setDbKey("file-3-key"));
+ ComponentDto file1 = db.components().insertComponent(newFileDto(project, null, "file-uuid-1").setDbKey("file-1-key"));
+ ComponentDto file2 = db.components().insertComponent(newFileDto(project, null, "file-uuid-2").setDbKey("file-2-key"));
MetricDto ncloc = newMetricDto().setKey("ncloc").setValueType(INT.name()).setDirection(1);
dbClient.metricDao().insert(dbSession, ncloc);
db.commit();
.setParam(PARAM_METRIC_PERIOD_SORT, "1")
.executeProtobuf(ComponentTreeWsResponse.class);
- assertThat(response.getComponentsList()).extracting("id").containsExactly("file-uuid-1", "file-uuid-2", "file-uuid-3");
+ assertThat(response.getComponentsList()).extracting("key").containsExactly("file-1-key", "file-2-key", "file-3-key");
}
@Test
public void remove_components_without_measure_on_the_metric_period_sort() {
ComponentDto project = db.components().insertPrivateProject();
SnapshotDto projectSnapshot = db.components().insertSnapshot(project);
- ComponentDto file4 = db.components().insertComponent(newFileDto(project, null, "file-uuid-4"));
- ComponentDto file3 = db.components().insertComponent(newFileDto(project, null, "file-uuid-3"));
- ComponentDto file2 = db.components().insertComponent(newFileDto(project, null, "file-uuid-2"));
- ComponentDto file1 = db.components().insertComponent(newFileDto(project, null, "file-uuid-1"));
+ ComponentDto file4 = db.components().insertComponent(newFileDto(project, null, "file-uuid-4").setDbKey("file-4-key"));
+ ComponentDto file3 = db.components().insertComponent(newFileDto(project, null, "file-uuid-3").setDbKey("file-3-key"));
+ ComponentDto file2 = db.components().insertComponent(newFileDto(project, null, "file-uuid-2").setDbKey("file-2-key"));
+ ComponentDto file1 = db.components().insertComponent(newFileDto(project, null, "file-uuid-1").setDbKey("file-1-key"));
MetricDto ncloc = newMetricDto().setKey("new_ncloc").setValueType(INT.name()).setDirection(1);
dbClient.metricDao().insert(dbSession, ncloc);
db.measures().insertLiveMeasure(file1, ncloc, m -> m.setData((String) null).setValue(null).setVariation(1.0d));
.setParam(PARAM_METRIC_SORT_FILTER, WITH_MEASURES_ONLY_METRIC_SORT_FILTER)
.executeProtobuf(ComponentTreeWsResponse.class);
- assertThat(response.getComponentsList()).extracting("id")
- .containsExactly("file-uuid-1", "file-uuid-2", "file-uuid-3")
- .doesNotContain("file-uuid-4");
+ assertThat(response.getComponentsList()).extracting("key")
+ .containsExactly("file-1-key", "file-2-key", "file-3-key")
+ .doesNotContain("file-4-key");
}
@Test
.isEmpty();
}
- @Test
- public void return_deprecated_id_in_the_response() {
- ComponentDto project = db.components().insertPrivateProject();
- SnapshotDto analysis = db.components().insertSnapshot(project);
- ComponentDto file = db.components().insertComponent(newFileDto(project));
- MetricDto ncloc = insertNclocMetric();
- db.measures().insertLiveMeasure(file, ncloc, m -> m.setValue(2d));
-
- ComponentTreeWsResponse response = ws.newRequest()
- .setParam(PARAM_COMPONENT, project.getKey())
- .setParam(PARAM_METRIC_KEYS, ncloc.getKey())
- .executeProtobuf(ComponentTreeWsResponse.class);
-
- assertThat(response.getBaseComponent().getId()).isEqualTo(project.uuid());
- assertThat(response.getComponentsList()).extracting(Component::getId)
- .containsExactlyInAnyOrder(file.uuid());
- }
-
- @Test
- public void use_deprecated_base_component_id_parameter() {
- ComponentDto project = db.components().insertPrivateProject();
- userSession.addProjectPermission(USER, project);
- insertNclocMetric();
-
- ComponentTreeWsResponse response = ws.newRequest()
- .setParam("baseComponentId", project.uuid())
- .setParam(PARAM_METRIC_KEYS, "ncloc")
- .executeProtobuf(ComponentTreeWsResponse.class);
-
- assertThat(response.getBaseComponent().getKey()).isEqualTo(project.getKey());
- }
-
- @Test
- public void use_deprecated_base_component_key_parameter() {
- ComponentDto project = db.components().insertPrivateProject();
- userSession.addProjectPermission(USER, project);
- insertNclocMetric();
-
- ComponentTreeWsResponse response = ws.newRequest()
- .setParam("baseComponentKey", project.getKey())
- .setParam(PARAM_METRIC_KEYS, "ncloc")
- .executeProtobuf(ComponentTreeWsResponse.class);
-
- assertThat(response.getBaseComponent().getKey()).isEqualTo(project.getKey());
- }
-
@Test
public void metric_without_a_domain() {
ComponentDto project = db.components().insertPrivateProject();
.executeProtobuf(ComponentTreeWsResponse.class);
assertThat(result.getComponentsList())
- .extracting(Component::getKey, Component::getRefId, Component::getRefKey)
- .containsExactlyInAnyOrder(tuple(projectCopy.getKey(), project.uuid(), project.getKey()));
+ .extracting(Component::getKey, Component::getRefKey)
+ .containsExactlyInAnyOrder(tuple(projectCopy.getKey(), project.getKey()));
}
@Test
.extracting(Component::getKey, Component::getBranch)
.containsExactlyInAnyOrder(applicationBranch.getKey(), applicationBranch.getBranch());
assertThat(result.getComponentsList())
- .extracting(Component::getKey, Component::getBranch, Component::getRefId, Component::getRefKey)
- .containsExactlyInAnyOrder(tuple(techProjectBranch.getKey(), projectBranch.getBranch(), projectBranch.uuid(), project.getKey()));
+ .extracting(Component::getKey, Component::getBranch, Component::getRefKey)
+ .containsExactlyInAnyOrder(tuple(techProjectBranch.getKey(), projectBranch.getBranch(), project.getKey()));
}
@Test
expectedException.expectMessage("Component key 'project-key' not found");
ws.newRequest()
- .setParam(DEPRECATED_PARAM_BASE_COMPONENT_KEY, "project-key")
+ .setParam(PARAM_COMPONENT, "project-key")
.setParam(PARAM_METRIC_KEYS, "ncloc")
.execute();
}
.execute();
}
- @Test
- public void fail_when_using_branch_uuid() {
- ComponentDto project = db.components().insertPrivateProject();
- userSession.logIn().addProjectPermission(UserRole.USER, project);
- ComponentDto branch = db.components().insertProjectBranch(project);
- insertNclocMetric();
-
- expectedException.expect(NotFoundException.class);
- expectedException.expectMessage(format("Component id '%s' not found", branch.uuid()));
-
- ws.newRequest()
- .setParam(DEPRECATED_PARAM_BASE_COMPONENT_ID, branch.uuid())
- .setParam(PARAM_METRIC_KEYS, "ncloc")
- .execute();
- }
-
private static MetricDto newMetricDto() {
return MetricTesting.newMetricDto()
.setWorstValue(null)