tests: support :needs_arm, :needs_intel metadata

This adds the ability to specify tests that depend on a certain CPU
architecture using `:needs_arm` or `:needs_intel`, similar to the
existing `:needs_macos` and `:needs_linux` metadata for tests that
depend on a certain OS.
This commit is contained in:
Sam Ford 2025-04-04 09:07:15 -04:00
parent 97cce36779
commit ed48426a33
No known key found for this signature in database
GPG Key ID: 7AF5CBEE1DD6F76D

View File

@ -134,6 +134,10 @@ module Homebrew
end
# rubocop:enable Homebrew/MoveToExtendOS
bundle_args << "--tag" << "~needs_arm" unless Hardware::CPU.arm?
bundle_args << "--tag" << "~needs_intel" unless Hardware::CPU.intel?
bundle_args << "--tag" << "~needs_network" unless args.online?
unless ENV["CI"]
bundle_args << "--tag" << "~needs_ci" \