diff options
| author | Josh Hagins | 2016-10-24 01:11:48 -0400 |
|---|---|---|
| committer | GitHub | 2016-10-24 01:11:48 -0400 |
| commit | 606a7623442924b9c828f3f3fbd227dd3122bf3c (patch) | |
| tree | 984a4d34c6cbe23151e4a95da35c9e8e420ff264 /Library/Homebrew/cask/test | |
| parent | 512a0c950e828fe07e629a629ba4d7b2fb8c2a6d (diff) | |
| parent | 0b8af5771f590bfb5cea7bccd4bd0fc77a973113 (diff) | |
| download | brew-606a7623442924b9c828f3f3fbd227dd3122bf3c.tar.bz2 | |
Merge pull request #1248 from Git-Jiro/add_reinstall_cmd_to_cask
add cask reinstall command
Diffstat (limited to 'Library/Homebrew/cask/test')
| -rw-r--r-- | Library/Homebrew/cask/test/cask/cli/reinstall_test.rb | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/Library/Homebrew/cask/test/cask/cli/reinstall_test.rb b/Library/Homebrew/cask/test/cask/cli/reinstall_test.rb new file mode 100644 index 000000000..22f0d23fd --- /dev/null +++ b/Library/Homebrew/cask/test/cask/cli/reinstall_test.rb @@ -0,0 +1,27 @@ +require "test_helper" + +describe Hbc::CLI::Reinstall do + it "allows reinstalling a Cask" do + shutup do + Hbc::CLI::Install.run("local-transmission") + end + Hbc.load("local-transmission").must_be :installed? + + shutup do + Hbc::CLI::Reinstall.run("local-transmission") + end + Hbc.load("local-transmission").must_be :installed? + end + + it "allows reinstalling a non installed Cask" do + shutup do + Hbc::CLI::Uninstall.run("local-transmission") + end + Hbc.load("local-transmission").wont_be :installed? + + shutup do + Hbc::CLI::Reinstall.run("local-transmission") + end + Hbc.load("local-transmission").must_be :installed? + end +end |
