summaryrefslogtreecommitdiff
path: root/test
AgeCommit message (Collapse)Author
2020-02-04Add the loaded feature after no exception raisedNobuyoshi Nakada
Retrying after rescued `require` should try to load the same library again. [Bug #16607] Notes: Merged: https://github.com/ruby/ruby/pull/2879
2020-02-04Do not warn CR inside string literalNobuyoshi Nakada
2020-02-04Fix inaccuracy in encoding testsLars Kanis
These tests assume Encoding.find('locale') == Encoding.find('external') and fail if they are distinct.
2020-02-03Fix SimpleDelegator respond_to? regressionJean Boussier
In 2.6, SimpleDelegator would always use the target `respond_to?` In 2.7.0 it doesn't if the target does not inherit from Object. This breaks compatibility for delegated objects that inherit from BasicObject and redefine `respond_to?`. Notes: Merged: https://github.com/ruby/ruby/pull/2875
2020-02-03Check type of empty keyword [Bug #16603]Seiei Miyagi
Co-authored-by: Yusuke Endoh <mame@ruby-lang.org> Notes: Merged: https://github.com/ruby/ruby/pull/2874
2020-02-03test/rubygems/test_gem_remote_fetcher.rb: Remove a duplicated testYusuke Endoh
https://rubyci.org/logs/rubyci.s3.amazonaws.com/ubuntu1604/ruby-master/log/20200203T003005Z.log.html.gz ``` /home/hsbt/chkbuild/tmp/build/20200203T003005Z/ruby/test/rubygems/test_gem_remote_fetcher.rb:485: warning: method redefined; discarding old test_fetch_path_socket_error /home/hsbt/chkbuild/tmp/build/20200203T003005Z/ruby/test/rubygems/test_gem_remote_fetcher.rb:167: warning: previous definition of test_fetch_path_socket_error was here ```
2020-02-01Merge the current master branch of rubygems/rubygems.Hiroshi SHIBATA
Just started to develop RubyGems 3.2.0.
2020-01-30delegate.rb: fixed keyword arguments in DelegateClassNobuyoshi Nakada
`Delegator.delegating_block` should delegate keyword arguments separately. [ruby-core:96949] Notes: Merged: https://github.com/ruby/ruby/pull/2852
2020-01-29Add more debug printKazuhiro NISHIYAMA
https://rubyci.org/logs/rubyci.s3.amazonaws.com/solaris11s-sunc/ruby-master/log/20200129T022510Z.fail.html.gz
2020-01-29skip SEGV (BUG) tests if ENV['RUBY_ON_BUG'] is given.Koichi Sasada
This environment variable can show additional message on BUG.
2020-01-29support multi-run for test/ruby/enc/test_regex_casefold.rbKoichi Sasada
should not mutate test data.
2020-01-29fix test cleanup.Koichi Sasada
should remove pathname.
2020-01-29Revert "srand() should not run in tests."Koichi Sasada
This reverts commit 4d132fa130e16eeb4af4177cfaccc00e05e2f864. There are discussions about using srand() in tests. I'll write a ticket about it and continue to discuss.
2020-01-29Revert "remove debug code."Koichi Sasada
This reverts commit 65768c80beb64a14c3e918f8ed5e41e9349025d0.
2020-01-29restore $LOADED_FEATURES.Koichi Sasada
Dir.tmpdir can return same directory because of rand() value, so we shouldn't rely on different name.
2020-01-29refactoring: use Proc and Constant.Koichi Sasada
2020-01-29ruby_reset_timezone resets leap_second_info.Tanaka Akira
[Bug #15177]
2020-01-28remove debug code.Koichi Sasada
2020-01-28srand() should not run in tests.Koichi Sasada
test_rand.rb calls srand() several times, however it change global rand-sequence (and --seeds doesn't have meaning). This patch makes such tests run in other processes. Notes: Merged: https://github.com/ruby/ruby/pull/2865
2020-01-28use Minitest::Unit.current_repeat_count to skip multi-run.Koichi Sasada
2020-01-28support multi-run for test/ruby/test_time.rbKoichi Sasada
ruby/test_time_tz.rb (not sure only this file affects) changes TZ and it seems to change internal state. This internal state change fails test_2038 and test_timegm on 2nd time execution. At this time I have no idea how to fix this issue, so I skips these tests on 2nd trial. You can try this failure with the following command without this patch. $ make test-all TESTS='--repeat-count=2 ruby/require ruby/time ruby/time_tz'
2020-01-28support multi-run for test/ruby/test_autoload.rbKoichi Sasada
Another test defines Object::A, but it will fail 2nd test.
2020-01-28support multi-run for test/ruby/test_struct.rbKoichi Sasada
Remove Structs to avoid redefinition warnings.
2020-01-28support multi-run for test/ruby/test_settracefunc.rbKoichi Sasada
need to remove Constants.
2020-01-28support multi-run for test/ruby/test_primitive.rbKoichi Sasada
need to redefine some classes.
2020-01-28support multi-run for test/ruby/test_refinement.rbKoichi Sasada
Give up to support multi-run: * test_method_should_use_refinements * test_instance_method_should_use_refinements I hope someone can revisit it.
2020-01-28support multi-run for test/ruby/test_proc.rbKoichi Sasada
Mysterious error: `remove_method(:foo) if method_defined?(:foo)` raise an exception `method `foo' not defined in #<Class:#<TestProc:0x000055d12ff154e0>>` This patch rename the method name foo to foo_arity to solve it.
2020-01-28support multi-run for test/ruby/test_module.rbKoichi Sasada
add cleanup code in some tests.
2020-01-28support multi-run for test/ruby/test_method.rbKoichi Sasada
need to restore a method.
2020-01-28support multi-run for test/ruby/test_marshal.rbKoichi Sasada
need to remove Constants.
2020-01-28support multi-run for test/ruby/test_iseq.rbKoichi Sasada
need to remove a Constant.
2020-01-28support multi-run for test/ruby/test_eval.rbKoichi Sasada
need to remove a Constant.
2020-01-28support multi-run for test/ruby/test_encoding.rbKoichi Sasada
Unique encoding name is required.
2020-01-28support multi-run for ruby/test_const.rbKoichi Sasada
need to redef Constants.
2020-01-28support multi-run for ruby/test_basicinstructions.rbKoichi Sasada
cvar should be initialized at first.
2020-01-28support multi-run for ruby/test_autoload.rbKoichi Sasada
It requires more cleanup.
2020-01-28support multiple run for test/ruby/test_array.Koichi Sasada
test-all supports multiple run with option --repeat-count=2 but test_equal_resize doesn't support it.
2020-01-27Check the encoding of `half:` optionNobuyoshi Nakada
2020-01-27Moved `GC.verify_compaction_references` to gc.rbNobuyoshi Nakada
And fixed a segfault by coercion of `Qundef`, when any keyword argument without `toward:` option is given.
2020-01-26Add more debug printKazuhiro NISHIYAMA
https://rubyci.org/logs/rubyci.s3.amazonaws.com/unstable11x/ruby-master/log/20200125T032406Z.fail.html.gz ``` IMAPTest#test_connection_closed_without_greeting [/export/home/rubyci/chkbuild-tmp/tmp/build/20200125T032406Z/ruby/test/net/imap/test_imap.rb:485]: [Net::IMAP::Error] exception expected, not #<RuntimeError: {:"server before close"=>"#<TCPServer:fd 10, AF_INET6, ::1, 48515>", :sock_addr=>["AF_INET6", 48515, "::1", "::1"], :sock_peeraddr=>["AF_INET6", 35223, "::1", "::1"], :e=>#<Errno::EINVAL: Invalid argument - connect(2) for [::1]:48515>, :server=>#<TCPServer:(closed)>, :port=>48515, :server_addr=>"::1"}>. ```
2020-01-26Use test_mode on Reline::History::Test for encodingaycabta
2020-01-25test/rinda/test_rinda.rb: Increase the timeoutYusuke Endoh
Attempts to fix a occational failure on Solaris with sunc https://rubyci.org/logs/rubyci.s3.amazonaws.com/solaris11-sunc/ruby-master/log/20200124T160008Z.fail.html.gz ``` 1) Error: Rinda::TestRingServer#test_do_reply: Timeout::Error: timeout ```
2020-01-25Recheck array length after `to_str` conversionNobuyoshi Nakada
https://hackerone.com/reports/244787
2020-01-25Recheck elements type after `to_str` conversionNobuyoshi Nakada
https://hackerone.com/reports/244786
2020-01-24Do not autosplat when calling proc with empty keyword splatJeremy Evans
With the removal of the splatted argument when using an empty keyword splat, the autosplat code considered an empty keyword splat the same as no argument at all. However, that results in autosplat behavior changing dependent on the content of the splatted hash, which is not what anyone would expect or want. This change always skips an autosplat if keywords were provided. Fixes [Bug #16560] Notes: Merged: https://github.com/ruby/ruby/pull/2861
2020-01-24brace the fact that lchmod(2) can EOPNOTSUPP卜部昌平
Musl libc has this function as a tiny wrapper of fchmodat(3posix). On the other hand Linux kernel does not support changing modes of a symlink. The operation always fails with EOPNOTSUPP. This fchmodat behaviour is defined in POSIX. We have to take care of such exceptions.
2020-01-24reroute musl unistd.h weirdness卜部昌平
Musl is (of course) not glibc. Its confstr(3) does not understand _CS_GNU_LIBC_VERSION. That's fair. Problem is, its unistd.h has that constant defined for unknown reason. We cannot blindly say the libc is glibc by looking at it. Instead we have to kick it, then see if it quacks like a duck. See https://git.musl-libc.org/cgit/musl/tree/include/unistd.h
2020-01-24pass appropriate libc path卜部昌平
The same as https://github.com/ruby/ruby/pull/2686, but for musl libc. Musl is not named as libc.so.6 so the `ldd` hack implemented some lines below does not work.
2020-01-23Remove empty keyword splats when calling even when using ruby2_keywordsJeremy Evans
Keeping empty keyword splats for ruby2_keywords methods was necessary in 2.7 to prevent the final positional hash being treated as keywords. Now that keyword argument separation has been committed, the final positional hash is never treated as keywords, so there is no need to keep empty keyword splats when using ruby2_keywords. Notes: Merged: https://github.com/ruby/ruby/pull/2857
2020-01-23Add more direct test for pp with a ruby2_keywords HashBenoit Daloze