Sha256: 4984d6db2be8462c31b7919d1c35c2291db61feb92990caa031d41fa1319eada
Contents?: true
Size: 729 Bytes
Versions: 83
Compression:
Stored size: 729 Bytes
Contents
require "pathname" require "yaml" require "open3" require "tempfile" if ARGV.empty? test_dirs = (Pathname(__dir__) + "../smoke").children else test_dirs = ARGV.map {|p| Pathname.pwd + p } end failed_tests = [] test_dirs.each do |dir| puts "Rebaselining #{dir}..." command = %w(steep check --save-expectations=test_expectations.yml) puts " command: #{command.join(" ")}" output, status = Open3.capture2(*command, chdir: dir.to_s) unless status.success? puts "Error!!! 👺" failed_tests << dir.basename end end if failed_tests.empty? puts "Successfully updated output expectations! 🤡" else puts "Failed to update the following tests! 💀" puts " #{failed_tests.join(", ")}" exit 1 end
Version data entries
83 entries across 83 versions & 3 rubygems