summaryrefslogtreecommitdiff
path: root/tool/lib/test/unit.rb
AgeCommit message (Collapse)Author
2025-12-19Extract `Test::JobServer` moduleNobuyoshi Nakada
A placeholder to handle GNU make jobserver option. spec/default.mspec didn't handle the jobserver using a FIFO.
2025-06-15Add `--keep-repeating` optionNobuyoshi Nakada
It directs the program to continue repeating the tests the specified number of times, even if any tests fail along the way.
2025-06-15Dump with debugger before killing stuck workerNobuyoshi Nakada
Notes: Merged: https://github.com/ruby/ruby/pull/13618
2025-03-06Show test task names longerNobuyoshi Nakada
Notes: Merged: https://github.com/ruby/ruby/pull/12871
2025-02-27[Misc #20661] Stop retrying tests in `make test-all` command by default (#11271)Naoto Ono
[Misc #20661] Stop retrying tests in make test-all command by default Notes: Merged-By: ono-max <onoto1998@gmail.com>
2024-09-10Remove an unnecessary blank line added by mistake [ci skip]Nobuyoshi Nakada
2024-09-10Add predicates for platformsNobuyoshi Nakada
Notes: Merged: https://github.com/ruby/ruby/pull/11583
2024-08-22`make test-tool` with Windows is broken. We should use :KILL with that platform.Hiroshi SHIBATA
``` [ 14/191] TestParallel::TestParallel#test_hungup = 11.02 s 1) Failure: TestParallel::TestParallel#test_hungup [C:/Users/hsbt/DevDrive/github.com/ruby/ruby/tool/test/testunit/test_parallel.rb:211]: Expected /^Retrying hung up testcases\.+$/ to match "Run options: \n" + " --seed=35582\n" + " --ruby\n" + " \".\\\\ruby.exe -I../../ruby/lib -I.ext/x64-mswin64_140 -I. ../../ruby/tool/runruby.rb --extout=.ext -- --disable-gems\"\n" + " -j\n" + " t1\n" + " --worker-timeout=1\n" + "\n" + "# Running tests:\n" + "\n" + "[1/1] 50340=test4test_hungup.\n" + "C:/Users/hsbt/DevDrive/github.com/ruby/ruby/tool/lib/test/unit.rb:418:in 'Process.kill': Invalid argument (Errno::EINVAL)\n" + ``` Notes: Merged: https://github.com/ruby/ruby/pull/11430
2024-08-07Use 20min for parallel test worker timeoutYusuke Endoh
2024-08-07Use SIGSEGV to kill a parallel test worker (to dump backtrace)Yusuke Endoh
2024-08-07Wait a bit longer for worker quitYusuke Endoh
2024-08-07Add a log when SIGKILL is sent to a test parallel workerYusuke Endoh
2024-08-06Use 3min for test parallel worker timeout againYusuke Endoh
Notes: Merged: https://github.com/ruby/ruby/pull/11315
2024-08-06Dump all-thread backtraces when test parallel worker exceeds time limitYusuke Endoh
Notes: Merged: https://github.com/ruby/ruby/pull/11315
2024-08-06Extend the default timeout of parallel testing to one hourYusuke Endoh
2024-08-06Extend the default timeout of parallel testingYusuke Endoh
Notes: Merged: https://github.com/ruby/ruby/pull/11311
2024-07-08Move the file location of launchable.rbNaoto Ono
2024-07-08Integrate Launchable into make btestNaoto Ono
2024-06-14Enable LeakChecker for RJIT previously disabled for MJIT (#10998)Alan Wu
RJIT doesn't spawn subprocesses so there should now be no need to special case it.
2024-05-08Show the caller location of assertion methodsNobuyoshi Nakada
Not only defined in `Test::Unit` or `CoreAssertions`, also show the caller location of assertion methods defined in the current class or ancestors.
2024-04-03Launchable: Add lineNumber fieldNaoto Ono
2024-04-02Launchable: Refactor the logic of JsonStreamWriterNaoto Ono
2024-02-29Inform failures in parallel tests before retryingNobuyoshi Nakada
Displays for each failure which test it actually occurred in. The output destination follows the --{stdout,stderr}-on-failure option.
2024-02-23Add Launchable into CINaoto Ono
2024-02-15Show the method owner in backtracesYusuke Endoh
``` test.rb:1:in 'Object#toplevel_meth': unhandled exception from test.rb:4:in 'Foo.class_meth' from test.rb:6:in 'Foo#instance_meth' from test.rb:11:in 'singleton_meth' from test.rb:13:in '<main>' ``` [Feature #19117]
2024-01-31Add newline between end and defNaoto Ono
2024-01-31Add the ability to generate Launchable test reportsNaoto Ono
2023-12-22Get rid of obsoleted RJITFirstTakashi Kokubun
It was renamed from test_mjit, but we did not maintain it as test_rjit. We test RJIT very differently.
2023-10-21Fallback job status to normal if no ttyNobuyoshi Nakada
2023-10-18Handle `Timeout::Error` reported from workersNobuyoshi Nakada
2023-10-18Fix total count when filters givenNobuyoshi Nakada
2023-10-18Escape method names containing control charactersNobuyoshi Nakada
2023-10-18Manage parallel test workers after timeoutNobuyoshi Nakada
2023-08-29Expose Test.filter_backtrace for the default gems.Hiroshi SHIBATA
Notes: Merged: https://github.com/ruby/ruby/pull/8313
2023-08-08Add message for `--ruby` option [ci skip]Nobuyoshi Nakada
2023-06-03Exit with a failure if any test files failed to loadNobuyoshi Nakada
Notes: Merged: https://github.com/ruby/ruby/pull/7897
2023-03-06s/mjit/rjit/Takashi Kokubun
Notes: Merged: https://github.com/ruby/ruby/pull/7462
2023-03-06s/MJIT/RJIT/Takashi Kokubun
Notes: Merged: https://github.com/ruby/ruby/pull/7462
2022-12-01Use class methods of `File` over `Kernel.open` and `IO.read`Nobuyoshi Nakada
Notes: Merged: https://github.com/ruby/ruby/pull/6834
2022-11-07jobserver option may not be at the lastNobuyoshi Nakada
2022-11-07Set `autoclose:` for inherited FDs only [ci skip]Nobuyoshi Nakada
2022-11-06GNU make 4.4 now uses a fifo for the jobserverNobuyoshi Nakada
2022-11-02Fix crash in test runner on timeoutPeter Zhu
When a test worker hangs and timeouts, the test runner crashes with the following stack trace: ruby/tool/lib/test/unit.rb:1747:in `puke': undefined method `backtrace' for Timeout::Error:Class (NoMethodError) from ruby/tool/lib/test/unit.rb:790:in `block in _run_parallel' from ruby/tool/lib/test/unit.rb:788:in `each' This commit adds handling for Timeout::Error and outputs a message.
2022-09-10Enable deprecation warnings for test-allBenoit Daloze
* So deprecated methods/constants/functions are dealt with early, instead of many tests breaking suddenly when removing a deprecated method/constant/function. * Follows https://bugs.ruby-lang.org/issues/17591 Notes: Merged: https://github.com/ruby/ruby/pull/6321
2022-07-05Add `--stdout-on-failure`, the reverse of `--stderr-on-failure`Nobuyoshi Nakada
2022-07-05Separate failed output optionNobuyoshi Nakada
It is unrelated to `GlobOption` at all.
2022-05-20Rename test_jit to test_mjitTakashi Kokubun
to avoid confusion with YJIT
2022-04-06Copyedit parallel test harness crash messageAlan Wu
Mea culpa. Co-authored-by: KaĆ­que Kandy Koga <kaiquekandykoga@gmail.com>
2022-04-06Copyedit parallel test harness crash messageAlan Wu
Notes: Merged: https://github.com/ruby/ruby/pull/5772
2022-04-05Try to fix NoMethodError on slow environmentsKazuhiro NISHIYAMA
``` 1) Failure: TestParallel::TestParallel#test_hungup [/home/user/ruby/tool/test/testunit/test_parallel.rb:215]: Expected /^Retrying hung up testcases\.+$/ to match "Run options: \n" + " --seed=43403\n" + " --ruby\n" + " \"./miniruby -I../lib -I. -I.ext/common ../tool/runruby.rb --extout=.ext -- --disable-gems\"\n" + " -j\n" + " t1\n" + " --worker-timeout=1\n" + "\n" + "# Running tests:\n" + "\n" + "/home/user/ruby/tool/lib/test/unit.rb:687:in `block in _run_parallel': undefined method `<' for nil:NilClass (NoMethodError)\n" + "\tfrom /home/user/ruby/tool/lib/test/unit.rb:538:in `block in quit_workers'\n" + "\tfrom /home/user/ruby/tool/lib/test/unit.rb:537:in `reject!'\n" + "\tfrom /home/user/ruby/tool/lib/test/unit.rb:537:in `quit_workers'\n" + "\tfrom /home/user/ruby/tool/lib/test/unit.rb:687:in `_run_parallel'\n" + "\tfrom /home/user/ruby/tool/lib/test/unit.rb:810:in `_run_suites'\n" + "\tfrom /home/user/ruby/tool/lib/test/unit.rb:849:in `_run_suites'\n" + "\tfrom /home/user/ruby/tool/lib/test/unit.rb:1479:in `_run_anything'\n" + "\tfrom /home/user/ruby/tool/lib/test/unit.rb:1263:in `_run_anything'\n" + "\tfrom /home/user/ruby/tool/lib/test/unit.rb:1654:in `run_tests'\n" + "\tfrom /home/user/ruby/tool/lib/test/unit.rb:1641:in `block in _run'\n" + "\tfrom /home/user/ruby/tool/lib/test/unit.rb:1640:in `each'\n" + "\tfrom /home/user/ruby/tool/lib/test/unit.rb:1640:in `_run'\n" + "\tfrom /home/user/ruby/tool/lib/test/unit.rb:1682:in `run'\n" + "\tfrom /home/user/ruby/tool/lib/test/unit.rb:1034:in `run'\n" + "\tfrom /home/user/ruby/tool/lib/test/unit.rb:882:in `run'\n" + "\tfrom /home/user/ruby/tool/lib/test/unit.rb:154:in `run'\n" + "\tfrom /home/user/ruby/tool/lib/test/unit.rb:1761:in `run'\n" + "\tfrom /home/user/ruby/tool/lib/test/unit.rb:1765:in `run'\n" + "\tfrom /home/user/ruby/tool/test/testunit/tests_for_parallel/runner.rb:14:in `<main>'\n". ```