Skip to content

Commit

Permalink
rspec-mock => 3.10.3 breaks hash argument
Browse files Browse the repository at this point in the history
  • Loading branch information
ramonskie committed Feb 10, 2022
1 parent 61fc3bc commit 57a4cd1
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/bosh_openstack_cpi/spec/unit/create_vm_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ def user_data(unique_name, network_spec, nameserver = nil, openssh = false)
allow(openstack.compute.key_pairs).to receive(:find).and_return(key_pair)
port_result_net = double('ports1', id: '117717c1-81cb-4ac4-96ab-99aaf1be9ca8', network_id: 'net', mac_address: 'AA:AA:AA:AA:AA:AA')
ports = double('Fog::OpenStack::Network::Ports')
allow(ports).to receive(:create).with(network_id: 'net', fixed_ips: [{ ip_address: '10.0.0.1' }], security_groups: ['default_sec_group_id']).and_return(port_result_net)
allow(ports).to receive(:create).with({network_id: 'net', fixed_ips: [{ ip_address: '10.0.0.1' }], security_groups: ['default_sec_group_id']}).and_return(port_result_net)
allow(openstack.network).to receive(:ports).and_return(ports)
end
end
Expand Down
2 changes: 1 addition & 1 deletion src/bosh_openstack_cpi/spec/unit/manual_network_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@
context "with 'use_nova_networking=false'" do
before(:each) do
allow(openstack).to receive(:network).and_return(neutron)
allow(ports).to receive(:create).with(network_id: 'net', fixed_ips: [{ ip_address: '10.0.0.1' }], security_groups: []).and_return(port)
allow(ports).to receive(:create).with({network_id: 'net', fixed_ips: [{ ip_address: '10.0.0.1' }], security_groups: []}).and_return(port)
allow(ports).to receive(:get).with('117717c1-81cb-4ac4-96ab-99aaf1be9ca8').and_return(port)
allow(neutron).to receive(:ports).and_return(ports)
end
Expand Down
2 changes: 1 addition & 1 deletion src/bosh_openstack_cpi/spec/unit/set_vm_metadata_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
it 'should only tag with metadata' do
metadata = { job: 'job', index: 'index' }

expect(Bosh::OpenStackCloud::TagManager).to receive(:tag_server).with(server, job: 'job', index: 'index')
expect(Bosh::OpenStackCloud::TagManager).to receive(:tag_server).with(server, { job: 'job', index: 'index'})

@cloud.set_vm_metadata('i-foobar', metadata)
end
Expand Down

0 comments on commit 57a4cd1

Please sign in to comment.