Sha256: 499d4f0724e108b03f9e36e36ba1a38f9d752200e450aa3b9001af3932cc2e4e
Contents?: true
Size: 689 Bytes
Versions: 10
Compression:
Stored size: 689 Bytes
Contents
require_relative 'executor' module SchemaDev class MatrixExecutor attr_reader :errors def initialize(matrix) @matrix = matrix end def run(cmd, dry_run: false) @errors = [] @matrix.each_with_index do |tuple, i| ruby = tuple[:ruby] rails = tuple[:rails] db = tuple[:db] label = "ruby #{ruby} - rails #{rails}" label += " - db #{db}" if db msg = "#{label} [#{i+1} of #{@matrix.size}]" puts "\n\n*** #{msg}\n\n" if not Executor.new(ruby: ruby, rails: rails, db: db).run(cmd, dry_run: dry_run) @errors << label end end return @errors.empty? end end end
Version data entries
10 entries across 10 versions & 1 rubygems