summaryrefslogtreecommitdiff
path: root/spec/tasks/gitlab/backup_rake_spec.rb
diff options
context:
space:
mode:
authorStan Hu <stanhu@gmail.com>2017-06-21 09:43:58 -0700
committerStan Hu <stanhu@gmail.com>2017-06-21 09:43:58 -0700
commit0f943c941bf0c7abc0358598f4a323b031bcca80 (patch)
tree7dd8ea3484252d469368498846c2c2b7f7500af4 /spec/tasks/gitlab/backup_rake_spec.rb
parent74fbc694de9a9cfe8a048c3c8d937f8e7068ce21 (diff)
parent043f8c260f49bb14f1c40ec563179c12c3df7828 (diff)
downloadgitlab-ce-0f943c941bf0c7abc0358598f4a323b031bcca80.tar.gz
Merge branch 'master' into sh-headless-chrome-support
Diffstat (limited to 'spec/tasks/gitlab/backup_rake_spec.rb')
-rw-r--r--spec/tasks/gitlab/backup_rake_spec.rb20
1 files changed, 10 insertions, 10 deletions
diff --git a/spec/tasks/gitlab/backup_rake_spec.rb b/spec/tasks/gitlab/backup_rake_spec.rb
index 1e5f55a738a..71580a788d0 100644
--- a/spec/tasks/gitlab/backup_rake_spec.rb
+++ b/spec/tasks/gitlab/backup_rake_spec.rb
@@ -47,24 +47,24 @@ describe 'gitlab:app namespace rake task' do
allow(Kernel).to receive(:system).and_return(true)
allow(FileUtils).to receive(:cp_r).and_return(true)
allow(FileUtils).to receive(:mv).and_return(true)
- allow(Rake::Task["gitlab:shell:setup"]).
- to receive(:invoke).and_return(true)
+ allow(Rake::Task["gitlab:shell:setup"])
+ .to receive(:invoke).and_return(true)
ENV['force'] = 'yes'
end
let(:gitlab_version) { Gitlab::VERSION }
it 'fails on mismatch' do
- allow(YAML).to receive(:load_file).
- and_return({ gitlab_version: "not #{gitlab_version}" })
+ allow(YAML).to receive(:load_file)
+ .and_return({ gitlab_version: "not #{gitlab_version}" })
- expect { run_rake_task('gitlab:backup:restore') }.
- to raise_error(SystemExit)
+ expect { run_rake_task('gitlab:backup:restore') }
+ .to raise_error(SystemExit)
end
it 'invokes restoration on match' do
- allow(YAML).to receive(:load_file).
- and_return({ gitlab_version: gitlab_version })
+ allow(YAML).to receive(:load_file)
+ .and_return({ gitlab_version: gitlab_version })
expect(Rake::Task['gitlab:db:drop_tables']).to receive(:invoke)
expect(Rake::Task['gitlab:backup:db:restore']).to receive(:invoke)
expect(Rake::Task['gitlab:backup:repo:restore']).to receive(:invoke)
@@ -310,8 +310,8 @@ describe 'gitlab:app namespace rake task' do
end
it 'does not invoke repositories restore' do
- allow(Rake::Task['gitlab:shell:setup']).
- to receive(:invoke).and_return(true)
+ allow(Rake::Task['gitlab:shell:setup'])
+ .to receive(:invoke).and_return(true)
allow($stdout).to receive :write
expect(Rake::Task['gitlab:db:drop_tables']).to receive :invoke