Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -85,15 +85,11 @@ public void testTriage() throws TimeoutException {

// wait for button to be enabled
_bot.waitUntil(triageButtonEnabled);


// check the first result is again the selected one after the revert


//assertEquals(resultName, getFirstToVerifyResultNode().getText());
// since the order of the list changes, we need to make sure that the changed result is in HIGH -> TO_VERIFY nodes
List<String> stateResults = getStateResultNodes("TO_VERIFY").stream().map(element -> (element.split(" ")[0] +" " +element.split(" ")[1]).trim()).collect(Collectors.toList());
assertTrue(stateResults.contains(resultName));
// split(" ")[0] provides the initial part of the name, which is the query id, both in the group and in resultName
List<String> stateResults = getStateResultNodes("TO_VERIFY").stream().map(element -> (element.split(" ")[0]).trim()).collect(Collectors.toList());
assertTrue(String.format("%s - %s", stateResults.toString(), resultName), stateResults.contains(resultName.split(" ")[0]));
// open changes tab
SWTBotTabItem changesTab = _bot.tabItemWithId(PluginConstants.CHANGES_TAB_ID);
changesTab.activate();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ public void testMissingSetCheckmarxServerUrl() throws TimeoutException {
sleep();

// After a sleep the missing Server Url message must be displayed
assertEquals(ERROR_SERVER_URL_NOT_SET, _bot.tree().cell(0, 0));
assertEquals( _bot.tree().cell(0, 0), ERROR_SERVER_URL_NOT_SET, _bot.tree().cell(0, 0));

// Close Checkmarx AST Scan view
_bot.viewByTitle(VIEW_CHECKMARX_AST_SCAN).close();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -467,7 +467,7 @@ private List<DisplayModel> groupByQueryName(List<DisplayModel> vulnerabilities){
Map<String, List<DisplayModel>> filteredByQueryName = new HashMap<>();

for (DisplayModel vulnerability : vulnerabilities) {
String queryName = vulnerability.getName();
String queryName = vulnerability.getQueryName();
if (filteredByQueryName.containsKey(queryName)) {
filteredByQueryName.get(queryName).add(vulnerability);
} else {
Expand Down