macOS Ventura (and related) test fixes

- fix `check_for_config_scripts` test, no idea why this wasn't working
- don't autoretry tests if `focus` or `byebug` are enabled
- add a ARM64 Ventura bottle symlink
This commit is contained in:
Mike McQuaid 2022-10-20 11:28:27 +01:00
parent 38cb504898
commit 416af82670
No known key found for this signature in database
GPG Key ID: 3338A31AFDB1D829
3 changed files with 8 additions and 3 deletions

View File

@ -91,11 +91,12 @@ describe Homebrew::Diagnostic::Checks do
end
specify "#check_for_config_scripts" do
mktmpdir do |path|
file = "#{path}/foo-config"
mktmpdir do |tmp|
file = "#{tmp}/foo-config"
FileUtils.touch file
FileUtils.chmod 0755, file
ENV["PATH"] = "#{path}#{File::PATH_SEPARATOR}#{ENV.fetch("PATH")}"
homebrew_path = "#{tmp}#{File::PATH_SEPARATOR}#{ENV.fetch("PATH")}"
stub_const("ORIGINAL_PATHS", PATH.new(homebrew_path).map { |path| Pathname.new(path).expand_path }.compact)
expect(checks.check_for_config_scripts)
.to match('"config" scripts exist')

View File

@ -225,6 +225,9 @@ RSpec.configure do |config|
if (example.metadata.keys & [:focus, :byebug]).empty? && !ENV.key?("HOMEBREW_VERBOSE_TESTS")
$stdout.reopen(File::NULL)
$stderr.reopen(File::NULL)
else
# don't retry when focusing/debugging
config.default_retry_count = 0
end
$stdin.reopen(File::NULL)

View File

@ -0,0 +1 @@
testball_bottle-0.1.yosemite.bottle.tar.gz