Nobuyoshi Nakada
b066260296
Follow up testunit
...
* Update method names.
* Sort shuffled tests by names.
2025-06-18 01:46:58 +09:00
Nobuyoshi Nakada
1a527929a5
Revert "Temporary pend unknown behavior of parallel tests"
...
This reverts commit 980f61935f
, which
seems no longer needed.
2025-06-18 01:46:58 +09:00
Yusuke Endoh
fc26004660
Remove test_retry_workers
...
The test fails randomly for unknown reason.
3956294509
```
1) Error:
TestParallel::TestParallel#test_retry_workers:
Test::Unit::ProxyError: execution expired (start: 2025-03-28 04:04:10 +0000, end: 2025-03-28 04:05:50 +0000)
/home/runner/work/ruby/ruby/src/tool/test/testunit/test_parallel.rb:16:in 'TestParallel.timeout'
/home/runner/work/ruby/ruby/src/tool/test/testunit/test_parallel.rb:225:in 'TestParallel::TestParallel#test_retry_workers'
```
Maybe the workers do not respond "quit" request.
We no longer use the retry mechanism, so just remove the test.
2025-03-28 14:19:33 +09:00
Yusuke Endoh
28c7ae6626
Try avoiding "invalid byte sequence in UTF-8"
2025-03-28 14:19:33 +09:00
Yusuke Endoh
12f8dda9e0
Report the actual time wated for timeout errors in TestParallel
2025-03-28 14:19:33 +09:00
Naoto Ono
2dff416ff2
Increase timeout in TestParallel testing to reduce flaky failures ( #12822 )
...
Currently, the following tests are flaky and failing intermittently, so I'm going to increase the timeout to improve stability.
```
1) Failure:
TestParallel::TestParallel#test_hungup [/Users/runner/work/ruby/ruby/src/tool/lib/zombie_hunter.rb:6]:
Expected [[42009, #<Process::Status: pid 42009 SIGKILL (signal 9)>]] to be empty.
2) Error:
TestParallel::TestParallel#test_hungup:
Test::Unit::ProxyError: execution expired
/Users/runner/work/ruby/ruby/src/lib/timeout.rb:40:in 'Timeout::Error.handle_timeout'
/Users/runner/work/ruby/ruby/src/lib/timeout.rb:194:in 'Timeout.timeout'
/Users/runner/work/ruby/ruby/src/tool/test/testunit/test_parallel.rb:210:in 'TestParallel::TestParallel#test_hungup'
```
3790150623 (step)
:14:105
```
1) Error:
TestParallel::TestParallel#test_retry_workers:
Test::Unit::ProxyError: execution expired
/Users/runner/work/ruby/ruby/src/lib/timeout.rb:40:in 'Timeout::Error.handle_timeout'
/Users/runner/work/ruby/ruby/src/lib/timeout.rb:194:in 'Timeout.timeout'
/Users/runner/work/ruby/ruby/src/tool/test/testunit/test_parallel.rb:217:in 'TestParallel::TestParallel#test_retry_workers'
```
3789904158 (step)
:14:106
2025-02-27 07:55:54 +00:00
Naoto Ono
48b6c60969
[Misc #20661 ] Stop retrying tests in make test-all
command by default ( #11271 )
...
[Misc #20661 ] Stop retrying tests in make test-all command by default
2025-02-27 06:12:02 +00:00
Nobuyoshi Nakada
4a67ef09cc
[Feature #21116 ] Extract RJIT as a third-party gem
2025-02-13 18:01:03 +09:00
Nobuyoshi Nakada
c51668d249
Add Test::Unit::CoreAssertions#assert_raise_kind_of
...
Similar to `Test::Unit::assert_raise`, but allows sub classes too.
2025-01-24 15:51:28 +09:00
Nobuyoshi Nakada
ae94fca788
Add test for Test::Unit::CoreAssertions#assert_raise_with_message
2025-01-24 15:53:08 +09:00
Peter Zhu
7eeabccf4c
Fix TestParallel#test_hungup when RUBY_TEST_TIMEOUT_SCALE is set
...
When RUBY_TEST_TIMEOUT_SCALE is set, the timeout increases by the multiple
specified. However, the test in test4test_hungup.rb does not scale, so
if RUBY_TEST_TIMEOUT_SCALE is a large number like 10, then the test will
not time out causing the tests test to fail.
2024-10-29 15:34:58 +09:00
Nobuyoshi Nakada
fcb058309b
Accept version range
...
Single `Integer` argument means an exact match to the major version.
2024-09-12 23:47:34 +09:00
Yusuke Endoh
062f85e141
Dump all-thread backtraces when test parallel worker exceeds time limit
2024-08-06 21:11:41 +09:00
Naoto Ono
8ede84aa95
Move the file location of launchable.rb
2024-07-08 10:15:04 +09:00
Naoto Ono
5b78925455
Integrate Launchable into make btest
2024-07-08 10:15:04 +09:00
Nobuyoshi Nakada
aabe718e64
Show the caller location of assertion methods
...
Not only defined in `Test::Unit` or `CoreAssertions`, also show the
caller location of assertion methods defined in the current class or
ancestors.
2024-05-08 17:24:36 +09:00
Koichi Sasada
9180e33ca3
show warning for unused block
...
With verbopse mode (-w), the interpreter shows a warning if
a block is passed to a method which does not use the given block.
Warning on:
* the invoked method is written in C
* the invoked method is not `initialize`
* not invoked with `super`
* the first time on the call-site with the invoked method
(`obj.foo{}` will be warned once if `foo` is same method)
[Feature #15554 ]
`Primitive.attr! :use_block` is introduced to declare that primitive
functions (written in C) will use passed block.
For minitest, test needs some tweak, so use
ea9caafc07
for `test-bundled-gems`.
2024-04-15 12:08:07 +09:00
Naoto Ono
56ecd8038a
Launchable: Add lineNumber field
2024-04-03 16:17:30 +09:00
Naoto Ono
3d1d1435c1
Launchable: Refactor the logic of JsonStreamWriter
2024-04-02 21:55:32 +09:00
KJ Tsanaktsidis
75234beb24
Make TestParallel#test_retry_workers consider RUBY_TEST_TIMEOUT_SCALE
...
This test currently fails if RUBY_TEST_TIMEOUT_SCALE is set, because the
worker timeout is scaled out but the duration of the sleep does not;
thus, the test-test-case does not timeout when it should.
2024-03-28 09:48:53 +11:00
Hiroshi SHIBATA
634e0ac140
Fix test failure with __runner_options__ renaming
2023-10-26 12:39:13 +09:00
lukeg
7717684d16
tool test/unit/testcase: rename vars @passed, @@current
...
to @__passed__, @@__current__.
@passed is redefined in a few test suites, and this could lead to bugs.
Also rename @options (Runner#options) to @__runner_options__, which is
only used in make test-tool anyway.
2023-10-26 12:39:13 +09:00
Nobuyoshi Nakada
4f4016497e
Handle Timeout::Error
reported from workers
2023-10-18 23:41:23 +09:00
Nobuyoshi Nakada
776d4dec69
Manage parallel test workers after timeout
2023-10-18 02:55:42 +09:00
Nobuyoshi Nakada
8b520bd3fb
Add jobs
optional keyword argument
2023-10-18 02:55:42 +09:00
Nobuyoshi Nakada
4589056384
Exit with a failure if any test files failed to load
2023-06-03 20:22:10 +09:00
Takashi Kokubun
2e875549a9
s/MJIT/RJIT/
2023-03-06 23:44:01 -08:00
Nobuyoshi Nakada
d903e76726
Allow strings in assert_pattern_list
2022-08-19 01:28:31 +09:00
Nobuyoshi Nakada
7c1ed47097
Add tests for assert_pattern_list
2022-08-18 23:38:56 +09:00
Nobuyoshi Nakada
56b45e8c8e
Let testunit use omit or pend instead of skip
2022-01-16 21:35:09 +09:00
Takashi Kokubun
1a63468831
Prepare for removing RubyVM::JIT ( #5262 )
2021-12-13 23:07:46 -08:00
Nobuyoshi Nakada
c7eac1be51
Retry hung up tests verbosely
2021-10-17 22:40:31 +09:00
Nobuyoshi Nakada
13716898df
Retry hung tests after parallel runs
2021-10-17 16:33:58 +09:00
Nobuyoshi Nakada
5de6e25144
Replace unpack with unpack1
2021-10-17 00:48:45 +09:00
Nobuyoshi Nakada
855db8e9ce
Use __dir__
2021-10-15 19:42:39 +09:00
Nobuyoshi Nakada
c4570acc86
Refactor ordering of tests
...
* Split the sorting types into classes.
* Apply the same sorting to method sorting under the parallel
test.
2021-10-04 20:46:47 +09:00
Nobuyoshi Nakada
34d6720fee
Prohibit test method redefinition
2021-09-17 08:54:18 +09:00
Hiroshi SHIBATA
43f49b2d1c
Fixup 455978cd13
2021-09-13 21:15:36 +09:00
Hiroshi SHIBATA
ec6f04c092
Use capture_output instead of capture_io
2021-09-13 21:14:42 +09:00
Hiroshi SHIBATA
8d0315a2bb
Removed unsed assertions for rubygems
2021-09-11 21:05:15 +09:00
Hiroshi SHIBATA
64e056a4c5
Drop to Ruby 1.8 related code
2021-09-11 18:10:15 +09:00
Hiroshi SHIBATA
a13ee1f33c
Removed rubinius support from test suite
2021-09-11 18:10:15 +09:00
Hiroshi SHIBATA
aebd0a873e
Removed maglev related code because it's not active status now
2021-09-11 18:10:15 +09:00
Hiroshi SHIBATA
d9025ee2b5
fixup f73f9e1f89
2021-09-11 15:29:16 +09:00
Hiroshi SHIBATA
d05383812a
Replace Test::Assertion and Test::Skip to Test::Unit::AssertionFailedError and Test::Unit::PendedError
2021-09-11 08:48:03 +09:00
Hiroshi SHIBATA
d7f0b41c7b
Surpressing the noisy messages
2021-09-11 08:48:03 +09:00
Hiroshi SHIBATA
980f61935f
Temporary pend unknown behavior of parallel tests
2021-09-11 08:48:03 +09:00
Hiroshi SHIBATA
566bbc2421
pend non-supported feature
2021-09-11 08:48:03 +09:00
Hiroshi SHIBATA
bc1c09c6e8
More fixed assertion message tests
2021-09-11 08:48:03 +09:00
Hiroshi SHIBATA
1c4f0f1eee
We prepared Test::Unit::TestCase in default value
2021-09-11 08:48:03 +09:00