diff options
author | Robert Speicher <robert@gitlab.com> | 2018-03-23 21:08:02 +0000 |
---|---|---|
committer | Robert Speicher <robert@gitlab.com> | 2018-03-23 21:08:02 +0000 |
commit | 93e216e6a5b3d3af08c054d662f8d361c812cecc (patch) | |
tree | b273bc06cec7c33277a1ff0fbe232a99a5bd3116 | |
parent | d6abee51894ba90c15b02202a6e1b5842b74cf00 (diff) | |
parent | 1f04248cd8f12c84ec093095f79cf0715153c3e2 (diff) | |
download | gitlab-ce-93e216e6a5b3d3af08c054d662f8d361c812cecc.tar.gz |
Merge branch '28857-followup-fix-pages-test' into 'master'
Fix a test that is going to break, that has not broken yet
See merge request gitlab-org/gitlab-ce!17966
-rw-r--r-- | spec/features/projects/pages_spec.rb | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/spec/features/projects/pages_spec.rb b/spec/features/projects/pages_spec.rb index 020738ae865..bdd49f731c7 100644 --- a/spec/features/projects/pages_spec.rb +++ b/spec/features/projects/pages_spec.rb @@ -244,10 +244,11 @@ feature 'Pages' do end context 'setting could not be updated' do + let(:service) { instance_double('Projects::UpdateService') } + before do - allow_any_instance_of(Projects::UpdateService) - .to receive(:execute) - .and_return(status: :error) + allow(Projects::UpdateService).to receive(:new).and_return(service) + allow(service).to receive(:execute).and_return(status: :error) end scenario 'tries to change the setting' do |