diff options
author | skippy <jonathan.yates.jones@gmail.com> | 2019-11-17 06:50:51 +0000 |
---|---|---|
committer | skippy <jonathan.yates.jones@gmail.com> | 2019-11-17 06:50:51 +0000 |
commit | 8d69df6f0bbfc08a17bdd7af5f17aff345203274 (patch) | |
tree | 3798e009ecbeff93635d05f8971ec3edf6655f75 /spec/support | |
parent | ec4547ebe04dd910ecedc6193cbf53e38f05d4cd (diff) | |
download | chef-8d69df6f0bbfc08a17bdd7af5f17aff345203274.tar.gz |
Resolved issues with tests not receiving exactly what they expected.
Resolved new method in linux_user not returning the correct array.
Signed-off-by: Jonathan Jones <gitmaster@thespooky.house>
Diffstat (limited to 'spec/support')
-rw-r--r-- | spec/support/shared/unit/provider/useradd_based_user_provider.rb | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/spec/support/shared/unit/provider/useradd_based_user_provider.rb b/spec/support/shared/unit/provider/useradd_based_user_provider.rb index a30f543e72..997d7350be 100644 --- a/spec/support/shared/unit/provider/useradd_based_user_provider.rb +++ b/spec/support/shared/unit/provider/useradd_based_user_provider.rb @@ -159,7 +159,7 @@ shared_examples_for "a useradd-based user provider" do |supported_useradd_option "-u", "1000", "-d", "/Users/mud", "-m", - "adam" ]) + "adam", {:returns=>[0,12]}]) expect(provider).to receive(:shell_out_compacted!).with(*command).and_return(true) provider.create_user end @@ -180,7 +180,7 @@ shared_examples_for "a useradd-based user provider" do |supported_useradd_option command.concat([ "-s", "/usr/bin/zsh", "-u", "1000", "-r", "-m", - "adam" ]) + "adam", {:returns=>[0]} ]) expect(provider).to receive(:shell_out_compacted!).with(*command).and_return(true) provider.create_user end @@ -203,7 +203,7 @@ shared_examples_for "a useradd-based user provider" do |supported_useradd_option "-g", "23", "-d", "/Users/mud", "-m", - "adam" ] + "adam", {:returns=>[0,12]}] expect(provider).to receive(:shell_out_compacted!).with(*command).and_return(true) provider.manage_user end @@ -214,7 +214,7 @@ shared_examples_for "a useradd-based user provider" do |supported_useradd_option "-g", "23", "-d", "/Users/mud", "-m", - "adam" ] + "adam", {:returns=>[0]}] expect(provider).to receive(:shell_out_compacted!).with(*command).and_return(true) provider.manage_user end @@ -223,7 +223,7 @@ shared_examples_for "a useradd-based user provider" do |supported_useradd_option expect(provider).to receive(:updating_home?).at_least(:once).and_return(false) command = ["usermod", "-g", "23", - "adam" ] + "adam", {:returns=>[0]} ] expect(provider).to receive(:shell_out_compacted!).with(*command).and_return(true) provider.manage_user end |