From f073747786abbe6ada55ed24b696a03e39c3c45d Mon Sep 17 00:00:00 2001 From: Lamont Granquist Date: Tue, 9 Feb 2016 07:53:56 -0800 Subject: auto fixing some rubocops Style/NegatedWhile Style/ParenthesesAroundCondition Style/WhileUntilDo Style/WordArray Performance/ReverseEach Style/ColonMethodCall --- spec/unit/provider/file/content_spec.rb | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'spec/unit/provider/file/content_spec.rb') diff --git a/spec/unit/provider/file/content_spec.rb b/spec/unit/provider/file/content_spec.rb index ebef4faa09..9ebcf10dcc 100644 --- a/spec/unit/provider/file/content_spec.rb +++ b/spec/unit/provider/file/content_spec.rb @@ -66,13 +66,13 @@ describe Chef::Provider::File::Content do it "returns a tempfile in the tempdir when :file_staging_uses_destdir is not set" do Chef::Config[:file_staging_uses_destdir] = false - expect(content.tempfile.path.start_with?(Dir::tmpdir)).to be_truthy + expect(content.tempfile.path.start_with?(Dir.tmpdir)).to be_truthy expect(canonicalize_path(content.tempfile.path).start_with?(enclosing_directory)).to be_falsey end it "returns a tempfile in the destdir when :file_deployment_uses_destdir is set" do Chef::Config[:file_staging_uses_destdir] = true - expect(content.tempfile.path.start_with?(Dir::tmpdir)).to be_falsey + expect(content.tempfile.path.start_with?(Dir.tmpdir)).to be_falsey expect(canonicalize_path(content.tempfile.path).start_with?(enclosing_directory)).to be_truthy end @@ -83,7 +83,7 @@ describe Chef::Provider::File::Content do it "returns a tempfile in the tempdir when :file_deployment_uses_destdir is set to :auto" do Chef::Config[:file_staging_uses_destdir] = :auto - expect(content.tempfile.path.start_with?(Dir::tmpdir)).to be_truthy + expect(content.tempfile.path.start_with?(Dir.tmpdir)).to be_truthy expect(canonicalize_path(content.tempfile.path).start_with?(enclosing_directory)).to be_falsey end @@ -93,7 +93,7 @@ describe Chef::Provider::File::Content do end it "returns a tempfile in the tempdir when :file_desployment_uses_destdir is not set" do - expect(content.tempfile.path.start_with?(Dir::tmpdir)).to be_truthy + expect(content.tempfile.path.start_with?(Dir.tmpdir)).to be_truthy expect(canonicalize_path(content.tempfile.path).start_with?(enclosing_directory)).to be_falsey end end -- cgit v1.2.1