summaryrefslogtreecommitdiff
path: root/spec/frontend/sentry/sentry_config_spec.js
diff options
context:
space:
mode:
Diffstat (limited to 'spec/frontend/sentry/sentry_config_spec.js')
-rw-r--r--spec/frontend/sentry/sentry_config_spec.js8
1 files changed, 6 insertions, 2 deletions
diff --git a/spec/frontend/sentry/sentry_config_spec.js b/spec/frontend/sentry/sentry_config_spec.js
index 1f5097ef2a8..9f67b681b8d 100644
--- a/spec/frontend/sentry/sentry_config_spec.js
+++ b/spec/frontend/sentry/sentry_config_spec.js
@@ -72,11 +72,13 @@ describe('SentryConfig', () => {
release: 'revision',
tags: {
revision: 'revision',
+ feature_category: 'my_feature_category',
},
};
beforeEach(() => {
jest.spyOn(Sentry, 'init').mockImplementation();
+ jest.spyOn(Sentry, 'setTags').mockImplementation();
sentryConfig.options = options;
sentryConfig.IGNORE_ERRORS = 'ignore_errors';
@@ -89,7 +91,6 @@ describe('SentryConfig', () => {
expect(Sentry.init).toHaveBeenCalledWith({
dsn: options.dsn,
release: options.release,
- tags: options.tags,
sampleRate: 0.95,
whitelistUrls: options.whitelistUrls,
environment: 'test',
@@ -98,6 +99,10 @@ describe('SentryConfig', () => {
});
});
+ it('should call Sentry.setTags', () => {
+ expect(Sentry.setTags).toHaveBeenCalledWith(options.tags);
+ });
+
it('should set environment from options', () => {
sentryConfig.options.environment = 'development';
@@ -106,7 +111,6 @@ describe('SentryConfig', () => {
expect(Sentry.init).toHaveBeenCalledWith({
dsn: options.dsn,
release: options.release,
- tags: options.tags,
sampleRate: 0.95,
whitelistUrls: options.whitelistUrls,
environment: 'development',