Commit e5a7ed3a authored by Luke "Jared" Bennett's avatar Luke "Jared" Bennett

Review changes

parent 12fbce2e
......@@ -5,7 +5,7 @@ const index = function index() {
sentryDsn: gon.sentry_dsn,
currentUserId: gon.current_user_id,
whitelistUrls: [gon.gitlab_url],
isProduction: gon.is_production,
isProduction: process.env.NODE_ENV,
});
return RavenConfig;
......
......@@ -12,7 +12,6 @@ module Gitlab
gon.katex_js_url = ActionController::Base.helpers.asset_path('katex.js')
gon.sentry_dsn = current_application_settings.clientside_sentry_dsn if current_application_settings.clientside_sentry_enabled
gon.gitlab_url = Gitlab.config.gitlab.url
gon.is_production = Rails.env.production?
if current_user
gon.current_user_id = current_user.id
......
......@@ -18,9 +18,10 @@ describe('RavenConfig options', () => {
sentry_dsn: sentryDsn,
current_user_id: currentUserId,
gitlab_url: gitlabUrl,
is_production: isProduction,
};
process.env.NODE_ENV = isProduction;
spyOn(RavenConfig, 'init');
indexReturnValue = index();
......
......@@ -157,10 +157,6 @@ describe('RavenConfig', () => {
RavenConfig.bindRavenErrors();
});
it('should query for document using jquery', () => {
expect(window.$).toHaveBeenCalledWith(document);
});
it('should call .on', function () {
expect($document.on).toHaveBeenCalledWith('ajaxError.raven', RavenConfig.handleRavenErrors);
});
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment