summaryrefslogtreecommitdiff
path: root/tool
diff options
context:
space:
mode:
authorHiroshi SHIBATA <hsbt@ruby-lang.org>2023-06-16 02:35:42 +0900
committerGitHub <noreply@github.com>2023-06-15 17:35:42 +0000
commitf6491773986ac77f728a42251edb7bfd33eedbf8 (patch)
tree933fae770a3ef91e611139ca987496b131acfb9b /tool
parent9fc2e66b75aceaca14a3dd683321fa7cb76521dc (diff)
Fix test-bundled-gems for Ruby 3.1 (#7935)
* pry is not needed for test-bundled-gems * Run test-unit test without rake task to avoid yard dependency * Try to skip Prime_test.rb
Diffstat (limited to 'tool')
-rw-r--r--tool/test-bundled-gems.rb13
1 files changed, 13 insertions, 0 deletions
diff --git a/tool/test-bundled-gems.rb b/tool/test-bundled-gems.rb
index ccf9d452ce..6f9a5e8738 100644
--- a/tool/test-bundled-gems.rb
+++ b/tool/test-bundled-gems.rb
@@ -33,6 +33,16 @@ File.foreach("#{gem_dir}/bundled_gems") do |line|
when "typeprof"
when "rbs"
+ # TODO: We should skip test file instead of test class/methods
+ skip_test_files = %w[
+ test/stdlib/Prime_test.rb
+ ]
+
+ skip_test_files.each do |file|
+ path = "#{gem_dir}/src/#{gem}/#{file}"
+ File.unlink(path) if File.exist?(path)
+ end
+
test_command << " stdlib_test validate"
first_timeout *= 3
@@ -52,6 +62,9 @@ File.foreach("#{gem_dir}/bundled_gems") do |line|
envs["RUBY_DEBUG_TEST_NO_REMOTE"] = "1"
end
+ when "test-unit"
+ test_command = "#{ruby} -C #{gem_dir}/src/#{gem} test/run-test.rb"
+
when /\Anet-/
toplib = gem.tr("-", "/")