summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLamont Granquist <lamont@scriptkiddie.org>2014-09-09 13:38:51 -0700
committerLamont Granquist <lamont@scriptkiddie.org>2014-09-09 13:38:51 -0700
commit652ddc46afa59c0228d1390b4a1c30197afca29d (patch)
tree318a7dbd8a04b61fe0289e5ff5dcbed7168b9887
parent3d933ab9fa547f58de846b4db588da47dbe11a8c (diff)
downloadchef-652ddc46afa59c0228d1390b4a1c30197afca29d.tar.gz
fixing travis LC_ALL errors
-rw-r--r--spec/unit/mixin/shell_out_spec.rb12
1 files changed, 6 insertions, 6 deletions
diff --git a/spec/unit/mixin/shell_out_spec.rb b/spec/unit/mixin/shell_out_spec.rb
index 744492a1a9..38a63a32ee 100644
--- a/spec/unit/mixin/shell_out_spec.rb
+++ b/spec/unit/mixin/shell_out_spec.rb
@@ -139,7 +139,7 @@ describe Chef::Mixin::ShellOut do
it "should set environment['LC_ALL'] to 'en_US.UTF-8' when 'LC_ALL' not present" do
options = { :environment => { 'HOME' => '/Users/morty' } }
expect(shell_out).to receive(:shell_out_command).with(cmd, {
- :environment => { 'HOME' => '/Users/morty', 'LC_ALL' => 'en_US.UTF-8' },
+ :environment => { 'HOME' => '/Users/morty', 'LC_ALL' => Chef::Config[:internal_locale] },
}).and_return(true)
shell_out.shell_out(cmd, options)
end
@@ -147,7 +147,7 @@ describe Chef::Mixin::ShellOut do
it "should not mutate the options hash when it adds LC_ALL" do
options = { :environment => { 'HOME' => '/Users/morty' } }
expect(shell_out).to receive(:shell_out_command).with(cmd, {
- :environment => { 'HOME' => '/Users/morty', 'LC_ALL' => 'en_US.UTF-8' },
+ :environment => { 'HOME' => '/Users/morty', 'LC_ALL' => Chef::Config[:internal_locale] },
}).and_return(true)
shell_out.shell_out(cmd, options)
expect(options[:environment].has_key?('LC_ALL')).to be false
@@ -170,7 +170,7 @@ describe Chef::Mixin::ShellOut do
it "should set env['LC_ALL'] to 'en_US.UTF-8' when 'LC_ALL' not present" do
options = { :env => { 'HOME' => '/Users/morty' } }
expect(shell_out).to receive(:shell_out_command).with(cmd, {
- :env => { 'HOME' => '/Users/morty', 'LC_ALL' => 'en_US.UTF-8' },
+ :env => { 'HOME' => '/Users/morty', 'LC_ALL' => Chef::Config[:internal_locale] },
}).and_return(true)
shell_out.shell_out(cmd, options)
end
@@ -178,7 +178,7 @@ describe Chef::Mixin::ShellOut do
it "should not mutate the options hash when it adds LC_ALL" do
options = { :env => { 'HOME' => '/Users/morty' } }
expect(shell_out).to receive(:shell_out_command).with(cmd, {
- :env => { 'HOME' => '/Users/morty', 'LC_ALL' => 'en_US.UTF-8' },
+ :env => { 'HOME' => '/Users/morty', 'LC_ALL' => Chef::Config[:internal_locale] },
}).and_return(true)
shell_out.shell_out(cmd, options)
expect(options[:env].has_key?('LC_ALL')).to be false
@@ -189,7 +189,7 @@ describe Chef::Mixin::ShellOut do
it "should add environment option and set environment['LC_ALL'] to 'en_US.UTF_8'" do
options = { :user => 'morty' }
expect(shell_out).to receive(:shell_out_command).with(cmd, {
- :user => 'morty', :environment => { 'LC_ALL' => 'en_US.UTF-8' },
+ :user => 'morty', :environment => { 'LC_ALL' => Chef::Config[:internal_locale] },
}).and_return(true)
shell_out.shell_out(cmd, options)
end
@@ -199,7 +199,7 @@ describe Chef::Mixin::ShellOut do
describe "when the last argument is not a Hash" do
it "should add environment options and set environment['LC_ALL'] to 'en_US.UTF-8'" do
expect(shell_out).to receive(:shell_out_command).with(cmd, {
- :environment => { 'LC_ALL' => 'en_US.UTF-8' },
+ :environment => { 'LC_ALL' => Chef::Config[:internal_locale] },
}).and_return(true)
shell_out.shell_out(cmd)
end