Merge pull request #13311 from bevanjkay/fix-outdated-greedy
cask: fix greedy outdated command
This commit is contained in:
commit
845925bf56
@ -173,13 +173,11 @@ module Cask
|
|||||||
version
|
version
|
||||||
end
|
end
|
||||||
|
|
||||||
if greedy || greedy_latest || (greedy_auto_updates && auto_updates)
|
|
||||||
if latest_version.latest?
|
if latest_version.latest?
|
||||||
return versions if outdated_download_sha?
|
return versions if (greedy || greedy_latest) && outdated_download_sha?
|
||||||
|
|
||||||
return []
|
return []
|
||||||
end
|
elsif auto_updates && !greedy && !greedy_auto_updates
|
||||||
elsif auto_updates
|
|
||||||
return []
|
return []
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
@ -160,7 +160,7 @@ describe Cask::Cask, :cask do
|
|||||||
|
|
||||||
describe "numbered version installed, :latest version in tap" do
|
describe "numbered version installed, :latest version in tap" do
|
||||||
include_examples ":latest cask", false, false, "latest",
|
include_examples ":latest cask", false, false, "latest",
|
||||||
["1.2.3"] => ["1.2.3"]
|
["1.2.3"] => []
|
||||||
include_examples ":latest cask", true, false, "latest",
|
include_examples ":latest cask", true, false, "latest",
|
||||||
["1.2.3"] => []
|
["1.2.3"] => []
|
||||||
include_examples ":latest cask", true, true, "latest",
|
include_examples ":latest cask", true, true, "latest",
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user