diff options
author | Francisco Javier López <fjlopez@gitlab.com> | 2019-07-19 14:11:27 +0300 |
---|---|---|
committer | Nick Thomas <nick@gitlab.com> | 2019-07-19 14:11:27 +0300 |
commit | 01685eed7674ec841b4249b42f9b350f4a105e4a (patch) | |
tree | 54d710450f9d7a99e6eb9daac4b65efc7bbda6c8 /spec/controllers/ide_controller_spec.rb | |
parent | 550ac6ef823d76a7274b562cd63d2dddafa65b2f (diff) |
Added Usage Data for some Web IDE actions
The actions tracked in the web IDE are:
- creation of commits
- creation of merge requests
- projects loaded
Diffstat (limited to 'spec/controllers/ide_controller_spec.rb')
-rw-r--r-- | spec/controllers/ide_controller_spec.rb | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/spec/controllers/ide_controller_spec.rb b/spec/controllers/ide_controller_spec.rb new file mode 100644 index 00000000000..0462f9520d5 --- /dev/null +++ b/spec/controllers/ide_controller_spec.rb @@ -0,0 +1,17 @@ +# frozen_string_literal: true + +require 'spec_helper' + +describe IdeController do + let(:user) { create(:user) } + + before do + sign_in(user) + end + + it 'increases the views counter' do + expect(Gitlab::UsageDataCounters::WebIdeCounter).to receive(:increment_views_count) + + get :index + end +end |