diff options
Diffstat (limited to 'spec/unit/resource')
-rw-r--r-- | spec/unit/resource/conditional_action_not_nothing_spec.rb | 4 | ||||
-rw-r--r-- | spec/unit/resource/conditional_spec.rb | 20 | ||||
-rw-r--r-- | spec/unit/resource/deploy_spec.rb | 4 | ||||
-rw-r--r-- | spec/unit/resource/remote_file_spec.rb | 24 | ||||
-rw-r--r-- | spec/unit/resource/scm_spec.rb | 8 | ||||
-rw-r--r-- | spec/unit/resource/subversion_spec.rb | 2 |
6 files changed, 31 insertions, 31 deletions
diff --git a/spec/unit/resource/conditional_action_not_nothing_spec.rb b/spec/unit/resource/conditional_action_not_nothing_spec.rb index 9f29de55f2..d140615cfc 100644 --- a/spec/unit/resource/conditional_action_not_nothing_spec.rb +++ b/spec/unit/resource/conditional_action_not_nothing_spec.rb @@ -27,7 +27,7 @@ describe Chef::Resource::ConditionalActionNotNothing do end it "indicates that resource convergence should not continue" do - expect(@conditional.continue?).to be_false + expect(@conditional.continue?).to be_falsey end end @@ -38,7 +38,7 @@ describe Chef::Resource::ConditionalActionNotNothing do end it "indicates that resource convergence should continue" do - expect(@conditional.continue?).to be_true + expect(@conditional.continue?).to be_truthy end end diff --git a/spec/unit/resource/conditional_spec.rb b/spec/unit/resource/conditional_spec.rb index cacac925b7..779c69425a 100644 --- a/spec/unit/resource/conditional_spec.rb +++ b/spec/unit/resource/conditional_spec.rb @@ -53,7 +53,7 @@ describe Chef::Resource::Conditional do end it "indicates that resource convergence should continue" do - expect(@conditional.continue?).to be_true + expect(@conditional.continue?).to be_truthy end end @@ -64,7 +64,7 @@ describe Chef::Resource::Conditional do end it "indicates that resource convergence should not continue" do - expect(@conditional.continue?).to be_false + expect(@conditional.continue?).to be_falsey end end @@ -75,7 +75,7 @@ describe Chef::Resource::Conditional do end it 'indicates that resource convergence should not continue' do - expect(@conditional.continue?).to be_false + expect(@conditional.continue?).to be_falsey end it 'should log a warning' do @@ -90,7 +90,7 @@ describe Chef::Resource::Conditional do end it "indicates that resource convergence should continue" do - expect(@conditional.continue?).to be_true + expect(@conditional.continue?).to be_truthy end end @@ -100,7 +100,7 @@ describe Chef::Resource::Conditional do end it "indicates that resource convergence should not continue" do - expect(@conditional.continue?).to be_false + expect(@conditional.continue?).to be_falsey end end end @@ -112,7 +112,7 @@ describe Chef::Resource::Conditional do end it "indicates that resource convergence should not continue" do - expect(@conditional.continue?).to be_false + expect(@conditional.continue?).to be_falsey end end @@ -123,7 +123,7 @@ describe Chef::Resource::Conditional do end it "indicates that resource convergence should continue" do - expect(@conditional.continue?).to be_true + expect(@conditional.continue?).to be_truthy end end @@ -134,7 +134,7 @@ describe Chef::Resource::Conditional do end it 'indicates that resource convergence should continue' do - expect(@conditional.continue?).to be_true + expect(@conditional.continue?).to be_truthy end it 'should log a warning' do @@ -149,7 +149,7 @@ describe Chef::Resource::Conditional do end it "indicates that resource convergence should not continue" do - expect(@conditional.continue?).to be_false + expect(@conditional.continue?).to be_falsey end end @@ -159,7 +159,7 @@ describe Chef::Resource::Conditional do end it "indicates that resource convergence should continue" do - expect(@conditional.continue?).to be_true + expect(@conditional.continue?).to be_truthy end end end diff --git a/spec/unit/resource/deploy_spec.rb b/spec/unit/resource/deploy_spec.rb index 6592fae26c..0403a7ba6b 100644 --- a/spec/unit/resource/deploy_spec.rb +++ b/spec/unit/resource/deploy_spec.rb @@ -115,9 +115,9 @@ describe Chef::Resource::Deploy do end it "has a boolean attribute for svn_force_export defaulting to false" do - expect(@resource.svn_force_export).to be_false + expect(@resource.svn_force_export).to be_falsey @resource.svn_force_export true - expect(@resource.svn_force_export).to be_true + expect(@resource.svn_force_export).to be_truthy expect {@resource.svn_force_export(10053)}.to raise_error(ArgumentError) end diff --git a/spec/unit/resource/remote_file_spec.rb b/spec/unit/resource/remote_file_spec.rb index 14d2fb97bc..3731d1aee2 100644 --- a/spec/unit/resource/remote_file_spec.rb +++ b/spec/unit/resource/remote_file_spec.rb @@ -113,40 +113,40 @@ describe Chef::Resource::RemoteFile do describe "ftp_active_mode" do it "should accept a boolean for the ftp_active_mode object" do @resource.ftp_active_mode true - expect(@resource.ftp_active_mode).to be_true + expect(@resource.ftp_active_mode).to be_truthy end it "should default to false" do - expect(@resource.ftp_active_mode).to be_false + expect(@resource.ftp_active_mode).to be_falsey end end describe "conditional get options" do it "defaults to using etags and last modified" do - expect(@resource.use_etags).to be_true - expect(@resource.use_last_modified).to be_true + expect(@resource.use_etags).to be_truthy + expect(@resource.use_last_modified).to be_truthy end it "enable or disables etag and last modified options as a group" do @resource.use_conditional_get(false) - expect(@resource.use_etags).to be_false - expect(@resource.use_last_modified).to be_false + expect(@resource.use_etags).to be_falsey + expect(@resource.use_last_modified).to be_falsey @resource.use_conditional_get(true) - expect(@resource.use_etags).to be_true - expect(@resource.use_last_modified).to be_true + expect(@resource.use_etags).to be_truthy + expect(@resource.use_last_modified).to be_truthy end it "disables etags indivdually" do @resource.use_etags(false) - expect(@resource.use_etags).to be_false - expect(@resource.use_last_modified).to be_true + expect(@resource.use_etags).to be_falsey + expect(@resource.use_last_modified).to be_truthy end it "disables last modified individually" do @resource.use_last_modified(false) - expect(@resource.use_last_modified).to be_false - expect(@resource.use_etags).to be_true + expect(@resource.use_last_modified).to be_falsey + expect(@resource.use_etags).to be_truthy end end diff --git a/spec/unit/resource/scm_spec.rb b/spec/unit/resource/scm_spec.rb index daabdd03ba..72319277ab 100644 --- a/spec/unit/resource/scm_spec.rb +++ b/spec/unit/resource/scm_spec.rb @@ -110,22 +110,22 @@ describe Chef::Resource::Scm do it "takes a boolean for #enable_submodules" do @resource.enable_submodules true - expect(@resource.enable_submodules).to be_true + expect(@resource.enable_submodules).to be_truthy expect {@resource.enable_submodules "lolz"}.to raise_error(ArgumentError) end it "defaults to not enabling submodules" do - expect(@resource.enable_submodules).to be_false + expect(@resource.enable_submodules).to be_falsey end it "takes a boolean for #enable_checkout" do @resource.enable_checkout true - expect(@resource.enable_checkout).to be_true + expect(@resource.enable_checkout).to be_truthy expect {@resource.enable_checkout "lolz"}.to raise_error(ArgumentError) end it "defaults to enabling checkout" do - expect(@resource.enable_checkout).to be_true + expect(@resource.enable_checkout).to be_truthy end it "takes a string for the remote" do diff --git a/spec/unit/resource/subversion_spec.rb b/spec/unit/resource/subversion_spec.rb index 4cbca9be11..5cd5d0de80 100644 --- a/spec/unit/resource/subversion_spec.rb +++ b/spec/unit/resource/subversion_spec.rb @@ -62,6 +62,6 @@ describe Chef::Resource::Subversion do it "hides password from custom exception message" do @svn.svn_password "l33th4x0rpa$$w0rd" e = @svn.customize_exception(Chef::Exceptions::Exec.new "Exception with password #{@svn.svn_password}") - expect(e.message.include?(@svn.svn_password)).to be_false + expect(e.message.include?(@svn.svn_password)).to be_falsey end end |