Add test for zap :login_item
This commit is contained in:
parent
3db0ad8ddf
commit
64d142af6e
|
@ -37,6 +37,8 @@ describe Hbc::Artifact::Zap do
|
|||
Hbc::FakeSystemCommand.stubs_command(['/usr/bin/sudo', '-E', '--', '/usr/bin/osascript', '-e', 'tell application "System Events" to count processes whose bundle identifier is "my.fancy.package.app"'], '1')
|
||||
Hbc::FakeSystemCommand.stubs_command(['/usr/bin/sudo', '-E', '--', '/usr/bin/osascript', '-e', 'tell application id "my.fancy.package.app" to quit'])
|
||||
|
||||
Hbc::FakeSystemCommand.expects_command(['/usr/bin/osascript', '-e', 'tell application "System Events" to delete every login item whose name is "Fancy"'])
|
||||
|
||||
Hbc::FakeSystemCommand.expects_command(['/usr/bin/sudo', '-E', '--', @cask.staged_path.join('MyFancyPkg','FancyUninstaller.tool'), '--please'])
|
||||
Hbc::FakeSystemCommand.expects_command(['/usr/bin/sudo', '-E', '--', '/bin/rm', '-rf', '--',
|
||||
Pathname.new('~/Library/Preferences/my.fancy.app.plist').expand_path])
|
||||
|
|
|
@ -12,5 +12,6 @@ cask :v1test => 'with-zap' do
|
|||
:args => %w[--please]
|
||||
},
|
||||
:quit => 'my.fancy.package.app',
|
||||
:login_item => 'Fancy',
|
||||
:delete => '~/Library/Preferences/my.fancy.app.plist'
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue