Commit 9c17b48e authored by Bob Van Landuyt's avatar Bob Van Landuyt

Merge branch 'vij-fix-tar-backup-spec' into 'master'

Fix broken spec covering non-tar backups

See merge request gitlab-org/gitlab!26651
parents b9b793ee b8f6474e
......@@ -319,18 +319,21 @@ describe Backup::Manager do
context 'when there is a non-tarred backup in the directory' do
before do
allow(Dir).to receieve(:glob).and_return(
allow(Dir).to receive(:glob).and_return(
[
'backup_information.yml'
]
)
allow(File).to receive(:exist?).and_return(true)
end
it 'selects the non-tarred backup to restore from' do
expect(Kernel).not_to receive(:system)
it 'selects the non-tarred backup to restore from' do
expect { subject.unpack }.to output.to_stdout
expect(progress).to have_received(:puts)
.with(a_string_matching('Non tarred backup found '))
expect(Kernel).not_to receive(:system)
end
subject.unpack
expect(progress).to have_received(:puts)
.with(a_string_matching('Non tarred backup found '))
end
end
end
......
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