Skip to content

Commit

Permalink
adept integration test to changes in command_wrapper
Browse files Browse the repository at this point in the history
command_wrapper tries to verify the connection (which includes sudo)
using a call to "echo". If this fails, it'll raise an error. This change
is now reflected in the test.

fixes #34.
  • Loading branch information
srenatus committed Dec 4, 2015
1 parent 8dd1acf commit 8168604
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions test/integration/sudo/passwd.rb
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
end

it 'is not running sudo without password' do
run_as('whoami', { sudo: true })
.exit_status.wont_equal 0
err = ->{Train.create('local', { sudo: true }).connection}.must_raise Train::UserError
err.message.must_match /Sudo requires a password/
end

it 'is running passwd sudo' do
Expand Down

0 comments on commit 8168604

Please sign in to comment.