summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorlamont-granquist <lamont@scriptkiddie.org>2014-09-09 18:31:17 -0700
committerlamont-granquist <lamont@scriptkiddie.org>2014-09-09 18:31:17 -0700
commit686f43d715a1be37189f05dc71ad2123356f0e55 (patch)
treeaa84dca4e80a04db0f15901638b0c9e5807c5fef
parent017b88a92a106d9e104988c904165423cbad4d39 (diff)
parent652ddc46afa59c0228d1390b4a1c30197afca29d (diff)
downloadchef-686f43d715a1be37189f05dc71ad2123356f0e55.tar.gz
Merge pull request #2020 from opscode/lcg/fix-lc-all-travis
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