summaryrefslogtreecommitdiff
path: root/tooling/bin/js_to_system_specs_mappings
blob: 3e9d9cb4c5fb15ad75a5eb41f36e49e071088223 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#!/usr/bin/env ruby
# frozen_string_literal: true

require_relative '../lib/tooling/mappings/js_to_system_specs_mappings'

changes        = ARGV.shift
matching_tests = ARGV.shift

changed_files = File.read(changes).split(' ')
matching_test_files = File.read(matching_tests).split(' ')

system_tests = Tooling::Mappings::JsToSystemSpecsMappings.new.execute(changed_files)

File.write(matching_tests, (matching_test_files + system_tests).join(' '))