Class: GitHubRunnerMatrix
Instance Attribute Summary collapse
-
#runners ⇒ Object
readonly
private
Instance Method Summary collapse
-
#active_runner_specs_hash ⇒ Array<RunnerSpecHash>
private
-
#initialize(testing_formulae, deleted_formulae, all_supported:, dependent_matrix:) ⇒ void
constructor
private
Constructor Details
#initialize(testing_formulae, deleted_formulae, all_supported:, dependent_matrix:) ⇒ void
This method is part of a private API. This method may only be used in the Homebrew/brew repository. Third parties should avoid using this method if possible, as it may be removed or changed without warning.
43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 |
# File 'github_runner_matrix.rb', line 43 def initialize(testing_formulae, deleted_formulae, all_supported:, dependent_matrix:) if all_supported && (testing_formulae.present? || deleted_formulae.present? || dependent_matrix) raise ArgumentError, "all_supported is mutually exclusive to other arguments" end @testing_formulae = T.let(testing_formulae, T::Array[TestRunnerFormula]) @deleted_formulae = T.let(deleted_formulae, T::Array[String]) @all_supported = T.let(all_supported, T::Boolean) @dependent_matrix = T.let(dependent_matrix, T::Boolean) @runners = T.let([], T::Array[GitHubRunner]) generate_runners! freeze end |
Instance Attribute Details
#runners ⇒ Object (readonly)
This method is part of a private API. This method may only be used in the Homebrew/brew repository. Third parties should avoid using this method if possible, as it may be removed or changed without warning.
33 34 35 |
# File 'github_runner_matrix.rb', line 33 def runners @runners end |
Instance Method Details
#active_runner_specs_hash ⇒ Array<RunnerSpecHash>
This method is part of a private API. This method may only be used in the Homebrew/brew repository. Third parties should avoid using this method if possible, as it may be removed or changed without warning.
60 61 62 63 64 |
# File 'github_runner_matrix.rb', line 60 def active_runner_specs_hash runners.select(&:active) .map(&:spec) .map(&:to_h) end |