formula: only include sha256
for core formulae in bottle JSON
This commit is contained in:
parent
d60f549a48
commit
aebaa7f8df
@ -1914,10 +1914,8 @@ class Formula
|
||||
bottle = bottle_hash
|
||||
|
||||
bottles = bottle["files"].map do |tag, file|
|
||||
info = {
|
||||
"url" => file["url"],
|
||||
"sha256" => file["sha256"],
|
||||
}
|
||||
info = { "url" => file["url"] }
|
||||
info["sha256"] = file["sha256"] unless tap.name == "homebrew/core"
|
||||
[tag.to_s, info]
|
||||
end.to_h
|
||||
|
||||
|
@ -886,8 +886,7 @@ describe Formula do
|
||||
expect(h).to be_a(Hash)
|
||||
expect(h["name"]).to eq "foo"
|
||||
expect(h["bottles"].keys).to eq [Utils::Bottles.tag.to_s, "x86_64_foo"]
|
||||
expect(h["bottles"][Utils::Bottles.tag.to_s].keys).to eq ["url", "sha256"]
|
||||
expect(h["bottles"][Utils::Bottles.tag.to_s]["sha256"]).to eq TEST_SHA256
|
||||
expect(h["bottles"][Utils::Bottles.tag.to_s].keys).to eq ["url"]
|
||||
expect(h["dependencies"]).to eq []
|
||||
end
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user