File tree Expand file tree Collapse file tree 3 files changed +10
-5
lines changed
main/java/org/sonar/api/server/rule/internal
test/java/org/sonar/api/server/rule/internal Expand file tree Collapse file tree 3 files changed +10
-5
lines changed Original file line number Diff line number Diff line change 1
1
# Changelog
2
+ ## 11.2
3
+ * Standard Severity BLOCKER is now mapped to Software Quality Impact Severity BLOCKER
4
+ * Standard Severity INFO is now mapped to Software Quality Impact Severity INFO
2
5
3
6
## 11.1
4
7
* Remove deprecation on ` status ` values ` TO_REVIEW ` , ` REVIEWED ` and related usages
Original file line number Diff line number Diff line change @@ -97,13 +97,15 @@ public static String convertToDeprecatedSeverity(Severity severity) {
97
97
public static Severity convertToImpactSeverity (String ruleSeverity ) {
98
98
switch (ruleSeverity ) {
99
99
case BLOCKER :
100
+ return Severity .BLOCKER ;
100
101
case CRITICAL :
101
102
return Severity .HIGH ;
102
103
case MAJOR :
103
104
return Severity .MEDIUM ;
104
105
case MINOR :
105
- case INFO :
106
106
return Severity .LOW ;
107
+ case INFO :
108
+ return Severity .INFO ;
107
109
default :
108
110
throw new IllegalStateException ("This severity value " + ruleSeverity + " is illegal." );
109
111
}
Original file line number Diff line number Diff line change @@ -152,17 +152,17 @@ public void convertToSeverity_givenMinor_returnLow() {
152
152
}
153
153
154
154
@ Test
155
- public void convertToSeverity_givenInfo_returnLow () {
155
+ public void convertToSeverity_givenInfo_returnInfo () {
156
156
Severity severity = ImpactMapper .convertToImpactSeverity ("INFO" );
157
157
158
- assertThat (severity ).isEqualTo (LOW );
158
+ assertThat (severity ).isEqualTo (INFO );
159
159
}
160
160
161
161
@ Test
162
- public void convertToSeverity_givenBlocker_returnHigh () {
162
+ public void convertToSeverity_givenBlocker_returnBlock () {
163
163
Severity severity = ImpactMapper .convertToImpactSeverity ("BLOCKER" );
164
164
165
- assertThat (severity ).isEqualTo (HIGH );
165
+ assertThat (severity ).isEqualTo (BLOCKER );
166
166
}
167
167
168
168
@ Test
You can’t perform that action at this time.
0 commit comments