Commit 5cd63ace authored by Thong Kuah's avatar Thong Kuah

Don't modify String in instance_configuration_spec

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