summaryrefslogtreecommitdiff
path: root/tool/lib/minitest
AgeCommit message (Collapse)Author
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-09-09Revert the related commits about `Tempfile.open` change.Hiroshi SHIBATA
Start with https://github.com/ruby/ruby/commit/fa21985a7a2f8f52a8bd82bd12a724e9dca74934 to https://github.com/ruby/ruby/commit/d7492a0be885ea9f2b9f71e3e95582f9a859c439
2020-08-29Simplify Tempfile.open calls with a block as they now unlink the file ↵Benoit Daloze
automatically
2020-07-28Use https instead of httpKazuhiro NISHIYAMA
2020-06-15Prefer String#each_byte when using a blockNobuyoshi Nakada
2020-06-15tool/lib/minitest/unit.rb: Reproducible shuffle of test suitesYusuke Endoh
... based on CRC32 of names of the test suites. Formerly, `make test-all` randomized the order of the test suites by using `Array#shuffle`. It also shows `--seed N` to reproduce the order, but it was not reproducible when a suite set is different. This change sorts the suites by CRC32 hash of the suite names with a salt generated by the seed.
2020-05-17Added --test-order=nosort optionNobuyoshi Nakada
Run tests in the order given in the command line.
2020-05-08Workaround for Minitest5Hiroshi SHIBATA
Notes: Merged: https://github.com/ruby/ruby/pull/3087
2020-04-23Initialize the class variable for Minitest::Unit.current_repeat_countNobuyoshi Nakada
2020-03-30Migrate {assert,refute}_patch_exits for compatibility with Minitest5Hiroshi SHIBATA
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-27MiniTest::Unit.options has default :seedKoichi Sasada
MiniTest::Unit (superclass of Test::Unit::Runner) does not has default seed parameter, but assigned after initializing. However some tests use MiniTest::Unit without setup of seed option and it cases unexpected test failures. To solve this issue, add default seed parameter 42.
2020-02-27`srand($seed)` at the beginning of each testKoichi Sasada
To avoid `srand(0)` effect in the other tests, call `srand($seed)` at the beginning of each test (setup). [Feature #16655]
2020-02-27Revert "`srand($seed)` at the beginning of each test"Koichi Sasada
This reverts commit 7c1553e91db07fed4fed3287b50304f1c69a685d. It breaks some tests.
2020-02-27`srand($seed)` at the beginning of each testKoichi Sasada
To avoid `srand(0)` effect in the other tests, call `srand($seed)` at the beginning of each test (setup). [Feature #16655]
2020-01-28Minitest::Unit.current_repeat_countKoichi Sasada
This method returns loop counter for multi-run (0 start).
2019-11-12tool/lib/leakchecker.rb: show the code location that allocated leaked fdYusuke Endoh
by using ObjectSpace.trace_object_allocations. `make test-all LEAK_CHECKER_TRACE_OBJECT_ALLOCATION=true` will print not only leaked fds but also where it was created.
2019-10-29tool/lib/minitest/unit.rb: add "omit" as an alias to "skip"Yusuke Endoh
According to rdoc, test-unit provides omit instead of skip. This is a compatibility layer to make it work with both test-unit and tool/lib/minitest.
2019-08-08Aliases capture_output to capture_io for test-unit compatiblity.Hiroshi SHIBATA
2019-07-31backtrace can be nil.Koichi Sasada
Surprisingly, on SystemStackError#backtrace can return nil.
2019-07-31Revert "add debug code"Koichi Sasada
This reverts commit e83ec207cd5fda973c41d6629d8504b515522b12.
2019-07-31add debug codeKoichi Sasada
2019-07-02Move to tool/lib from test/lib.Hiroshi SHIBATA