From 4cf9b5785e2a2afb2e3cd34e9a46e6669de64701 Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Sat, 13 Jul 2024 15:44:05 -0400 Subject: [PATCH] test/{formula,dev-cmd/test}_spec: fix failures --- Library/Homebrew/test/dev-cmd/test_spec.rb | 2 +- Library/Homebrew/test/formula_spec.rb | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Library/Homebrew/test/dev-cmd/test_spec.rb b/Library/Homebrew/test/dev-cmd/test_spec.rb index 0eb0dc8b2151f..7fce00709a1fa 100644 --- a/Library/Homebrew/test/dev-cmd/test_spec.rb +++ b/Library/Homebrew/test/dev-cmd/test_spec.rb @@ -30,7 +30,7 @@ RUBY expect { brew "test", "--verbose", "testball_offline_test" } - .to output(/curl: \(6\) Could not resolve host: example\.org/).to_stdout + .to output(/curl: \(7\) Failed to connect to example.org/).to_stdout .and be_a_failure end end diff --git a/Library/Homebrew/test/formula_spec.rb b/Library/Homebrew/test/formula_spec.rb index bb1b9fd5c8e6d..ae7e6b47df4e1 100644 --- a/Library/Homebrew/test/formula_spec.rb +++ b/Library/Homebrew/test/formula_spec.rb @@ -42,7 +42,7 @@ expect(f.alias_name).to be_nil expect(f.full_alias_name).to be_nil expect(f.specified_path).to eq(path) - [:build, :test, :postinstall].each { |phase| expect(f.network_access_allowed?(phase)).to be(true) } + [:build, :test, :postinstall].each { |phase| expect(f.network_access_allowed?(phase)).to be(false) } expect { klass.new }.to raise_error(ArgumentError) end @@ -56,7 +56,7 @@ expect(f_alias.specified_path).to eq(Pathname(alias_path)) expect(f_alias.full_alias_name).to eq(alias_name) expect(f_alias.full_specified_name).to eq(alias_name) - [:build, :test, :postinstall].each { |phase| expect(f_alias.network_access_allowed?(phase)).to be(true) } + [:build, :test, :postinstall].each { |phase| expect(f_alias.network_access_allowed?(phase)).to be(false) } expect { klass.new }.to raise_error(ArgumentError) end