diff options
author | Ian Baum <ibaum@gitlab.com> | 2018-02-12 23:21:32 +0300 |
---|---|---|
committer | Ian Baum <ibaum@gitlab.com> | 2018-02-12 23:22:29 +0300 |
commit | 47b750a4f9384d95a1266292e162334fc0b80cbd (patch) | |
tree | c174d2658c0b15f6b837ba8957e5f4e83c920fe8 /spec | |
parent | e607fd796657afd214b8f25201919d3e33b3f35f (diff) |
Merge branch 'sh-disable-query-limiter' into 'master'
Disable query limiting warnings for now on GitLab.com
See merge request gitlab-org/gitlab-ce!17067
Diffstat (limited to 'spec')
-rw-r--r-- | spec/lib/gitlab/query_limiting_spec.rb | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/spec/lib/gitlab/query_limiting_spec.rb b/spec/lib/gitlab/query_limiting_spec.rb index 2eddab0b8c3..42877b1e2dd 100644 --- a/spec/lib/gitlab/query_limiting_spec.rb +++ b/spec/lib/gitlab/query_limiting_spec.rb @@ -12,14 +12,16 @@ describe Gitlab::QueryLimiting do expect(described_class.enable?).to eq(true) end - it 'returns true on GitLab.com' do + it 'returns false on GitLab.com' do + expect(Rails.env).to receive(:development?).and_return(false) + expect(Rails.env).to receive(:test?).and_return(false) allow(Gitlab).to receive(:com?).and_return(true) - expect(described_class.enable?).to eq(true) + expect(described_class.enable?).to eq(false) end - it 'returns true in a non GitLab.com' do - expect(Gitlab).to receive(:com?).and_return(false) + it 'returns false in a non GitLab.com' do + allow(Gitlab).to receive(:com?).and_return(false) expect(Rails.env).to receive(:development?).and_return(false) expect(Rails.env).to receive(:test?).and_return(false) |