cask/cmd: fix tests
This commit is contained in:
parent
01e894e9c6
commit
7a0471f4c9
@ -47,7 +47,7 @@ describe Cask::Cmd::Create, :cask do
|
|||||||
it "raises an exception when more than one Cask is given" do
|
it "raises an exception when more than one Cask is given" do
|
||||||
expect {
|
expect {
|
||||||
described_class.run("additional-cask", "another-cask")
|
described_class.run("additional-cask", "another-cask")
|
||||||
}.to raise_error(UsageError, /Only one cask can be created at a time\./)
|
}.to raise_error(Homebrew::CLI::NumberOfNamedArgumentsError)
|
||||||
end
|
end
|
||||||
|
|
||||||
it "raises an exception when the Cask already exists" do
|
it "raises an exception when the Cask already exists" do
|
||||||
|
|||||||
@ -21,7 +21,7 @@ describe Cask::Cmd::Edit, :cask do
|
|||||||
it "raises an error when given more than one argument" do
|
it "raises an error when given more than one argument" do
|
||||||
expect {
|
expect {
|
||||||
described_class.new("local-caffeine", "local-transmission")
|
described_class.new("local-caffeine", "local-transmission")
|
||||||
}.to raise_error(UsageError, /Only one cask can be edited at a time\./)
|
}.to raise_error(Homebrew::CLI::NumberOfNamedArgumentsError)
|
||||||
end
|
end
|
||||||
|
|
||||||
it "raises an exception when the Cask doesn't exist" do
|
it "raises an exception when the Cask doesn't exist" do
|
||||||
|
|||||||
@ -6,7 +6,7 @@ shared_examples "a command that requires a Cask token" do
|
|||||||
it "raises an exception " do
|
it "raises an exception " do
|
||||||
expect {
|
expect {
|
||||||
described_class.run
|
described_class.run
|
||||||
}.to raise_error(UsageError, /this command requires a .*cask.* argument/)
|
}.to raise_error(UsageError, /This command requires .*cask.* argument/)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user