summaryrefslogtreecommitdiff
path: root/tool/lib/test
AgeCommit message (Collapse)Author
2020-12-24Pass keyword options in assert_syntax_errorNobuyoshi Nakada
2020-12-23[ruby/date] Workaround for non-ruby repository like ruby/date, flori/jsonHiroshi SHIBATA
https://github.com/ruby/date/commit/1ff7fa2d80
2020-12-20Add `require_relative` option to `assert_ractor`Marc-Andre Lafortune
2020-12-19`assert_ractor` tweak. Thanks NobuMarc-Andre Lafortune
2020-12-19Add `assert_ractor` [Feature #17367]Marc-Andre Lafortune
Notes: Merged: https://github.com/ruby/ruby/pull/3942
2020-12-18Use category: :deprecated in warnings that are related to deprecationJeremy Evans
Also document that both :deprecated and :experimental are supported :category option values. The locations where warnings were marked as deprecation warnings was previously reviewed by shyouhei. Comment a couple locations where deprecation warnings should probably be used but are not currently used because deprecation warning enablement has not occurred at the time they are called (RUBY_FREE_MIN, RUBY_HEAP_MIN_SLOTS, -K). Add assert_deprecated_warn to test assertions. Use this to simplify some tests, and fix failing tests after marking some warnings with deprecated category. Notes: Merged: https://github.com/ruby/ruby/pull/3917
2020-12-17test/ruby: Check warning messages at a finer granularityNobuyoshi Nakada
Instead of suppressing all warnings wholly in each test scripts by setting `$VERBOSE` to `nil` in `setup` methods. Notes: Merged: https://github.com/ruby/ruby/pull/3925 Merged-By: nobu <nobu@ruby-lang.org>
2020-12-13Debug the command used for gdb dumpTakashi Kokubun
It's not working http://ci.rvm.jp/results/trunk-mjit@phosphorus-docker/3288206. I'm debugging why.
2020-12-12Dump a backtrace with gdbTakashi Kokubun
Because Ruby often fails to dump a C backtrace.
2020-12-03Avoid leaving too many core files in /tmpTakashi Kokubun
for CIs like ci.rvm.jp.
2020-12-03Do not require time and fileutils by defaultTakashi Kokubun
I have no idea what I'm doing, but the previous commit caused lots of CI failures like https://github.com/ruby/ruby/runs/1496949568 and this place is the most suspicious.
2020-12-03Save a core file on a worker crashTakashi Kokubun
CI failures like http://ci.rvm.jp/results/trunk-mjit@phosphorus-docker/3280458 doesn't provide any useful information, and it doesn't leave a core file in a CI environment because a test like `Process.kill(:TRAP, $$)` overwrites in a next run very quickly. Thus I'd like to keep core files in /tmp.
2020-12-03Revert "Report a full_message on a worker crash"Takashi Kokubun
This reverts commit 00f046ef57f9da7f5248f9ef9d55702ddc407bf1. It was not helpful for an issue I was debugging.
2020-12-01tune parallel testKoichi Sasada
This patch contains the fowllowing hacks: (1) Add "--timetable-data=FILE" option for test-all This option enables to dump timeline event contains worker, suite, and start/end time. (2) remove TestJIT in test_jit_debug.rb on parallel test. it is duplicated test. (3) move test_jit.rb and test_jit_debug.rb at first because these two tests are bottleneck of parallel tests. On my environment, `make test-all TESTS=-j12` reduced the total time 190 seconds -> 140 seconds. Notes: Merged: https://github.com/ruby/ruby/pull/3826
2020-11-24Report a full_message on a worker crashTakashi Kokubun
A worker crash happens very often, but we're not sure why. I'd like to know a backtrace if it's available.
2020-10-27freeze dynamic regexp literalsKoichi Sasada
Regexp literals are frozen, and also dynamically comppiled Regexp literals (/#{expr}/) are frozen. Notes: Merged: https://github.com/ruby/ruby/pull/3676
2020-10-08Expose assert, assert_respond_to and assert_not_respond_to for default gems.Hiroshi SHIBATA
2020-09-14Added just working Test::Unit::CoreAssertions#diffNobuyoshi Nakada
This is not "diff", but show expected and actual results both, just to get rid of `NoMethodError` when an assertion failed.
2020-07-02Expose `assert_pattern_list` for drb test with test-unit gem.Hiroshi SHIBATA
2020-05-17Added --test-order=nosort optionNobuyoshi Nakada
Run tests in the order given in the command line.
2020-04-23Expand retrying test file names to realpathNobuyoshi Nakada
As well as worker processes do in Test::Unit::Worker#run.
2020-04-17Rescue EPIPE in _reportNobuyoshi Nakada
Instead of letting callers rescue the error always.
2020-04-17core_assertions.rb: fixed fd leak at timeoutNobuyoshi Nakada
Notes: Merged: https://github.com/ruby/ruby/pull/3039
2020-03-04tool/lib/test/unit: support TESTS='-- -ext-' again卜部昌平
There is a test directory named test/-ext-. Because this directry starts with a hyphen, we have to cheat test/unit in order for it to run the tests underneath. TESTS='-- -ext' worked for a long time. Let's not break that maneuver.
2020-03-01show backtrace.Koichi Sasada
assert_nothing_raised doesn't show the backtrace if an exception is thrown in a block. This patch shows this backtrace.
2020-02-28respect --test-order=randomKoichi Sasada
Now --test-order=random is simply ignored. This patch respect this option. Notes: Merged: https://github.com/ruby/ruby/pull/2932
2020-02-27don't ignore `--seed` optionKoichi Sasada
`--seed N` option is just ignored so respect this option. [Feature #16655] Also making "Run options" display pretty.
2020-02-11Expose assert_no_memory_leak for weakrefHiroshi SHIBATA
Notes: Merged: https://github.com/ruby/ruby/pull/2900
2020-02-11Expose assert_normal_exit for weakrefHiroshi SHIBATA
Notes: Merged: https://github.com/ruby/ruby/pull/2900
2020-02-07Stop auto runnerNobuyoshi Nakada
Auto runner should not run in forked processes in separated tests.
2020-02-07No crafted backtrace for SystemExitNobuyoshi Nakada
As SystemExit is ignored, it is just useless.
2020-02-06Fixed the output from separated test in parallel testNobuyoshi Nakada
Redirect the output of separated child process to `MiniTest::Unit.output`.
2020-02-06Add separated assertion countNobuyoshi Nakada
2020-02-05Fixed the output from separated test in parallel testNobuyoshi Nakada
To output to the STDOUT of the parent process according to the parallel test protocol, should send to the `MiniTest::Unit.output` instead of each own STDOUT.
2020-02-05Fixed FD leaksNobuyoshi Nakada
2020-02-05Get rid of nested string interpolations to be editor-friendlyNobuyoshi Nakada
2020-02-04just use STDOUTNARUSE, Yui
2020-02-04On Windows it cannot receive fd except 0..2NARUSE, Yui
2020-02-04assert_separately uses their own pipe instead of stdoutNARUSE, Yui
2019-12-12implement make test-all TESTS=--gc-compact卜部昌平
79eb5e1acac2339c6ec71db723298bdfcd92b233 implemented RUBY_TEST_GC_COMPACT=1 so why not make it also possible via the command line argument.
2019-12-12support gc_compact_checker on parallel test.Koichi Sasada
2019-12-03tool/lib/test/unit/parallel.rb: fail explicitly when failing to get ioYusuke Endoh
`(ulimit -n 30; make test-tool)` fails with unexplicit message: "undefined method `write' for nil:NilClass" due to lack of stdout. This change makes it explicit. [Bug #5577]
2019-12-01[ruby/fileutils] Fix test failure under ruby 2.4David Rodríguez
`Exception#full_message` is only defined on ruby 2.5.0 and above. https://github.com/ruby/fileutils/commit/a8968f41ed
2019-12-01[ruby/fileutils] Fix error printing test failureDavid Rodríguez
`exception_details` is not defined anywhere. This commit fixes the following test crash in ruby 2.4 ``` Error: test_assert_output_lines(TestFileUtils): NoMethodError: undefined method `exception_details' for #<TestFileUtils:0x00005556ef699178> ``` And replaces it with an actual test failure: ``` [Test::Unit::CoreAssertions::MiniTest::Assertion] exception expected, not #<NoMethodError: undefined method `full_message' for #<RuntimeError: ok> Did you mean? message>. ``` https://github.com/ruby/fileutils/commit/2f38ba6e82
2019-11-09Add debug printKazuhiro NISHIYAMA
http://ci.rvm.jp/results/trunk-mjit@silicon-docker/2380788 ``` test_all #<Thread:0x000055b6c8e9fca8@/tmp/ruby/v2/src/trunk-mjit/tool/lib/test/unit/parallel.rb:42 run> terminated with exception (report_on_exception is true): <internal:pack>:134:in `pack': no implicit conversion of false into String (TypeError) from /tmp/ruby/v2/src/trunk-mjit/tool/lib/test/unit/parallel.rb:160:in `_report' from /tmp/ruby/v2/src/trunk-mjit/tool/lib/test/unit/parallel.rb:45:in `block in _run_suite' ```
2019-10-31Try to run assert_output_unchanged with racc testsHiroshi SHIBATA
Notes: Merged: https://github.com/ruby/ruby/pull/2635
2019-10-23Catch syntax error even if fatalNobuyoshi Nakada
2019-10-16Revert "alias assert_raise_message for compatibility with test-unit"Nobuyoshi Nakada
This reverts commit 43015275b9a7f2833c93ad11ea96ae4cb3b7acd7. `assert_raise_message` in test-unit is different from `assert_raise_with_message`. It checks the exception message only, but not the exception class,
2019-10-16alias assert_raise_message for compatibility with test-unitNobuyoshi Nakada
2019-10-03[ruby/fileutils] improve the compatibility of minitestHiroshi SHIBATA
https://github.com/ruby/fileutils/commit/f16f5a0dd6