Skip to content

Commit

Permalink
Fix various issues
Browse files Browse the repository at this point in the history
  • Loading branch information
Sancretor committed Jan 18, 2022
1 parent 453c4f1 commit da9877c
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@
import fr.cnes.sonar.report.model.Rule;
import fr.cnes.sonar.report.utils.StringManager;

/**
* Class used to format Issues data for reports
*/
public class IssuesAdapter {

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@
import fr.cnes.sonar.report.model.SecurityHotspot;
import fr.cnes.sonar.report.utils.StringManager;

/**
* Class used to format Security Hotspots data for reports
*/
public class SecurityHotspotsAdapter {

/**
Expand Down
14 changes: 7 additions & 7 deletions src/test/ut/java/fr/cnes/sonar/report/CommonTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -168,18 +168,18 @@ public void before() {
report.setIssues(issues);

List<Map<String,String>> rawIssues = new ArrayList<>();
Map issue1 = new HashMap<>();
issue1.put("Comments", new ArrayList<String>());
issue1.put("ToReview", true);
issue1.put("someNumber", 1.0);
Map<String, String> issue1 = new HashMap<>();
issue1.put("Comments", new ArrayList<String>().toString());
issue1.put("ToReview", "true");
issue1.put("someNumber", "1.0");
rawIssues.add(issue1);

Map issue2 = new HashMap<>();
Map<String,String> issue2 = new HashMap<>();
List<String> list = new ArrayList<>();
list.add("Element 1");
list.add("Element 2");
issue2.put("Comments", list);
issue2.put("someNumber", 2.0);
issue2.put("Comments", list.toString());
issue2.put("someNumber", "2.0");
rawIssues.add(issue2);

report.setRawIssues(rawIssues);
Expand Down

0 comments on commit da9877c

Please sign in to comment.