Skip to content

Commit

Permalink
Fixed SecureFindingRestApiIT. Removed uppercasing of the detector type (
Browse files Browse the repository at this point in the history
#247)

Signed-off-by: Stevan Buzejic <[email protected]>
  • Loading branch information
stevanbz authored Jan 10, 2023
1 parent 6ce8d6e commit 8b7f1fd
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -280,13 +280,13 @@ public void testGetFindings_byDetectorType_success() throws IOException {

// Call GetFindings API for first detector
Map<String, String> params = new HashMap<>();
params.put("detectorType", detector1.getDetectorType().toUpperCase());
params.put("detectorType", detector1.getDetectorType());
Response getFindingsResponse = makeRequest(userReadOnlyClient, "GET", SecurityAnalyticsPlugin.FINDINGS_BASE_URI + "/_search", params, null);
Map<String, Object> getFindingsBody = entityAsMap(getFindingsResponse);
Assert.assertEquals(1, getFindingsBody.get("total_findings"));
// Call GetFindings API for second detector
params.clear();
params.put("detectorType", detector2.getDetectorType().toUpperCase());
params.put("detectorType", detector2.getDetectorType());
getFindingsResponse = makeRequest(userReadOnlyClient, "GET", SecurityAnalyticsPlugin.FINDINGS_BASE_URI + "/_search", params, null);
getFindingsBody = entityAsMap(getFindingsResponse);
Assert.assertEquals(1, getFindingsBody.get("total_findings"));
Expand Down

0 comments on commit 8b7f1fd

Please sign in to comment.