Don't modify String in instance_configuration_spec

This commit is contained in:
Thong Kuah 2019-04-01 12:07:50 +13:00
parent 3a1a12b383
commit 5cd63ace04
1 changed files with 2 additions and 2 deletions

View File

@ -32,8 +32,8 @@ describe InstanceConfiguration do
end
def stub_pub_file(exist: true)
path = 'spec/fixtures/ssh_host_example_key.pub'
path << 'random' unless exist
path = exist ? 'spec/fixtures/ssh_host_example_key.pub' : 'spec/fixtures/ssh_host_example_key.pub.random'
allow(subject).to receive(:ssh_algorithm_file).and_return(Rails.root.join(path))
end
end