Skip to content

Commit 18f9bde

Browse files
authored
Refactor matrix script
1 parent 2327de0 commit 18f9bde

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

generate-test-matrix.rb

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,8 @@ def unique_versions(versions, segment_count, *symbolic)
3333
macos_runners = runners.select { |runner| runner.start_with?('macos-') }
3434
ubuntu_runners = runners.select { |runner| runner.start_with?('ubuntu-') }
3535
windows_runners, non_windows_runners = runners.partition { |runner| runner.start_with?('windows-') }
36-
macos_intel_runners = runners.grep(/macos.+intel/)
3736

38-
macos_arm64_runners, _macos_x64_runners = macos_runners.partition { |runner| !runner.end_with?('-intel')}
37+
macos_arm64_runners, macos_x64_runners = macos_runners.partition { |runner| !runner.end_with?('-intel')}
3938
ubuntu_arm64_runners, ubuntu_x64_runners = ubuntu_runners.partition { |runner| runner.end_with?('-arm')}
4039
windows_arm64_runners, windows_x64_runners = windows_runners.partition { |runner| runner.end_with?('-arm') }
4140

@@ -75,6 +74,6 @@ def unique_versions(versions, segment_count, *symbolic)
7574
# RubyInstaller windows-arm64 builds only exist for Ruby 3.4+
7675
matrix -= windows_arm64_runners.product(%w[2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 3.0 3.1 3.2 3.3])
7776
# TruffleRuby 34+ does not support macOS Intel
78-
matrix -= macos_intel_runners.product(%w[truffleruby-head truffleruby+graalvm-head])
77+
matrix -= macos_x64_runners.product(%w[truffleruby-head truffleruby+graalvm-head])
7978

8079
puts(JSON.generate(matrix.sort.map { |os, ruby| { os:, ruby: } }))

0 commit comments

Comments
 (0)