From bbe0d9dae399f9ada9751a43ca4761b6ebf3109b Mon Sep 17 00:00:00 2001 From: Gael Chamoulaud Date: Thu, 1 Oct 2015 09:35:18 +0200 Subject: [PATCH] Fix RSpec 3.x syntax - 7 conversions from: it { should ... } to: it { is_expected.to ... } Change-Id: I1e148b1a457e720e2ef61172cad477917d6498b4 Signed-off-by: Gael Chamoulaud --- spec/classes/cinder_volume_pure_spec.rb | 8 ++++---- spec/defines/cinder_backend_pure_spec.rb | 2 +- spec/defines/cinder_type_set_spec.rb | 4 ++-- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/spec/classes/cinder_volume_pure_spec.rb b/spec/classes/cinder_volume_pure_spec.rb index 4cf8d633..208800ec 100644 --- a/spec/classes/cinder_volume_pure_spec.rb +++ b/spec/classes/cinder_volume_pure_spec.rb @@ -15,7 +15,7 @@ describe 'cinder::volume::pure' do end it 'configure pure volume driver' do - should contain_cinder__backend__pure('DEFAULT') + is_expected.to contain_cinder__backend__pure('DEFAULT') end end @@ -28,7 +28,7 @@ describe 'cinder::volume::pure' do end it 'configure pure volume driver' do - should contain_cinder__backend__pure('DEFAULT').with({ + is_expected.to contain_cinder__backend__pure('DEFAULT').with({ :pure_storage_protocol => 'iSCSI', :use_chap_auth => 'true' }) @@ -41,7 +41,7 @@ describe 'cinder::volume::pure' do end it 'configure pure volume driver' do - should contain_cinder__backend__pure('DEFAULT').with({ + is_expected.to contain_cinder__backend__pure('DEFAULT').with({ :pure_storage_protocol => 'FC' }) end @@ -53,7 +53,7 @@ describe 'cinder::volume::pure' do end it 'configure pure volume with additional configuration' do - should contain_cinder__backend__pure('DEFAULT').with({ + is_expected.to contain_cinder__backend__pure('DEFAULT').with({ :extra_options => {'pure_backend/param1' => {'value' => 'value1'}} }) end diff --git a/spec/defines/cinder_backend_pure_spec.rb b/spec/defines/cinder_backend_pure_spec.rb index 433fe651..c04670e8 100644 --- a/spec/defines/cinder_backend_pure_spec.rb +++ b/spec/defines/cinder_backend_pure_spec.rb @@ -61,7 +61,7 @@ describe 'cinder::backend::pure' do end it 'configure pure volume with additional configuration' do - should contain_cinder__backend__pure('pure').with({ + is_expected.to contain_cinder__backend__pure('pure').with({ :extra_options => {'pure_backend/param1' => {'value' => 'value1'}} }) end diff --git a/spec/defines/cinder_type_set_spec.rb b/spec/defines/cinder_type_set_spec.rb index 9218b3bd..1c3d4d02 100644 --- a/spec/defines/cinder_type_set_spec.rb +++ b/spec/defines/cinder_type_set_spec.rb @@ -19,7 +19,7 @@ describe 'cinder::type_set' do describe 'by default' do let(:params){ default_params } it 'should have its execs' do - should contain_exec('cinder type-key sith set monchichi=hippo').with( + is_expected.to contain_exec('cinder type-key sith set monchichi=hippo').with( :command => 'cinder type-key sith set monchichi=hippo', :unless => "cinder extra-specs-list | grep -Eq '\\bsith\\b.*\\bmonchichi\\b.*\\bhippo\\b'", :environment => [ @@ -36,7 +36,7 @@ describe 'cinder::type_set' do default_params.merge({:value => 'hippi'}) } it 'should have its execs' do - should contain_exec('cinder type-key sith set monchichi=hippi').with( + is_expected.to contain_exec('cinder type-key sith set monchichi=hippi').with( :command => 'cinder type-key sith set monchichi=hippi', :unless => "cinder extra-specs-list | grep -Eq '\\bsith\\b.*\\bmonchichi\\b.*\\bhippi\\b'", :environment => [