Fix analytics_spec.rb test to pass when run from M1
This commit is contained in:
parent
371122da55
commit
e2fc14b0b7
@ -14,7 +14,9 @@ describe Utils::Analytics do
|
|||||||
it "returns OS_VERSION and prefix when HOMEBREW_PREFIX is a custom prefix" do
|
it "returns OS_VERSION and prefix when HOMEBREW_PREFIX is a custom prefix" do
|
||||||
allow(Hardware::CPU).to receive(:type).and_return(:intel)
|
allow(Hardware::CPU).to receive(:type).and_return(:intel)
|
||||||
allow(Homebrew).to receive(:default_prefix?).and_return(false)
|
allow(Homebrew).to receive(:default_prefix?).and_return(false)
|
||||||
expect(described_class.os_arch_prefix_ci).to include("#{OS_VERSION}, #{described_class.custom_prefix_label}")
|
arch = ", #{described_class.arch_label}" if described_class.arch_label.present?
|
||||||
|
expected = "#{OS_VERSION}#{arch}, #{described_class.custom_prefix_label}"
|
||||||
|
expect(described_class.os_arch_prefix_ci).to include(expected)
|
||||||
end
|
end
|
||||||
|
|
||||||
it "does not include prefix when HOMEBREW_PREFIX is the default prefix" do
|
it "does not include prefix when HOMEBREW_PREFIX is the default prefix" do
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user