aboutsummaryrefslogtreecommitdiffstats
path: root/server/sonar-web/src/main/js/helpers/constants.ts
diff options
context:
space:
mode:
authorWouter Admiraal <wouter.admiraal@sonarsource.com>2020-07-10 17:04:41 +0200
committersonartech <sonartech@sonarsource.com>2020-09-03 20:07:20 +0000
commit3914a4b0a3936faf140f7343e368fd28aca90004 (patch)
tree0f7815a64300489400f14f7add8f69fda031e9b7 /server/sonar-web/src/main/js/helpers/constants.ts
parent6b84d18a99ca282fc029d62f8807270537cf80ef (diff)
downloadsonarqube-3914a4b0a3936faf140f7343e368fd28aca90004.tar.gz
sonarqube-3914a4b0a3936faf140f7343e368fd28aca90004.zip
SONAR-13597 Add scope distribution to issues page
Diffstat (limited to 'server/sonar-web/src/main/js/helpers/constants.ts')
-rw-r--r--server/sonar-web/src/main/js/helpers/constants.ts7
1 files changed, 6 insertions, 1 deletions
diff --git a/server/sonar-web/src/main/js/helpers/constants.ts b/server/sonar-web/src/main/js/helpers/constants.ts
index 2e101a490d0..5bf81e56973 100644
--- a/server/sonar-web/src/main/js/helpers/constants.ts
+++ b/server/sonar-web/src/main/js/helpers/constants.ts
@@ -18,7 +18,8 @@
* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
import { colors } from '../app/theme';
-import { IssueType } from '../types/issues';
+import { ComponentQualifier } from '../types/component';
+import { IssueScope, IssueType } from '../types/issues';
export const SEVERITIES = ['BLOCKER', 'CRITICAL', 'MAJOR', 'MINOR', 'INFO'];
export const STATUSES = ['OPEN', 'REOPENED', 'CONFIRMED', 'RESOLVED', 'CLOSED'];
@@ -28,6 +29,10 @@ export const ISSUE_TYPES: T.IssueType[] = [
IssueType.CodeSmell,
IssueType.SecurityHotspot
];
+export const SOURCE_SCOPES = [
+ { scope: IssueScope.Main, qualifier: ComponentQualifier.File },
+ { scope: IssueScope.Test, qualifier: ComponentQualifier.TestFile }
+];
export const RULE_TYPES: T.RuleType[] = ['BUG', 'VULNERABILITY', 'CODE_SMELL', 'SECURITY_HOTSPOT'];
export const RULE_STATUSES = ['READY', 'BETA', 'DEPRECATED'];