summaryrefslogtreecommitdiff
path: root/test
AgeCommit message (Collapse)Author
2013-12-13* ext/socket/lib/socket.rb: Don't test $! in "ensure" clause becauseakr
it may be set before the body. Reported by ko1 and mrkn. [ruby-core:59088] [Bug #9247] * lib/cgi/core.rb: Ditto. * lib/drb/ssl.rb: Ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44184 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-13proc.c: fix inherited ownernobu
* proc.c (mnew_from_me): achieve the original defined_class from prepended iclass, to fix inherited owner. * proc.c (method_owner): return the defined class, but not the class which the method object is created from. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44179 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-13test_weakmap.rb: fix testnobu
* test/ruby/test_weakmap.rb (test_include?): create target object in a block, so that collected soon as possible. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44178 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-13test/ruby: better assertionsnobu
* test/ruby: use better assertions instead of mere assert. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44177 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-13test_weakmap.rb: fix testnobu
* test/ruby/test_weakmap.rb (test_include?): Object.new does not excute the block, use tap. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44176 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-13proc.c, vm_method.c: fix super and aliasnobu
* proc.c (method_owner): return the class where alias is defined, not the class original method is defined. * vm_method.c (rb_method_entry_make, rb_alias): store the originally defined class in me. [Bug #7993] [Bug #7842] [Bug #9236] * vm_method.c (rb_method_entry_get_without_cache): cache included module but not iclass. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44175 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-13test_weakmap.rb: fix testnobu
* test/ruby/test_weakmap.rb (test_include?): isolate weak referenced object. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44174 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-13test/ruby: better assertionsnobu
* test/ruby: use better assertions instead of mere assert. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44173 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-13assertions.rb: last match in assert_raise_with_messagenobu
* lib/test/unit/assertions.rb (assert_raise_with_message): set caller's last match if expected is a Regexp. * test/ruby/test_arity.rb (err_mess): use assert_raise_with_message. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44172 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-13* error.c: add Exception#backtrace_locations.ko1
Now, there are no setter and independent from Exception#backtrace. [Feature #8960] * eval.c (setup_exception): set backtrace locations for `bt_location' special attribute. * vm_backtrace.c (rb_backtrace_to_location_ary): added. * internal.h: ditto. * test/ruby/test_backtrace.rb: add a test for Exception#backtrace_locations. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44170 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-13* lib/rubygems/request_set/lockfile.rb: Import RubyGems master a8d0669drbrain
with a 1.8.7 compatibility fix. * test/rubygems/test_gem_request_set_lockfile.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44159 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-13* lib/rubygems: Update to RubyGems master ddac51f. Changes:drbrain
* Allow override for the shared gem installation directory for rubygems packagers. * Lock gem cache files for read and write to improve thread safety. * Use io/console when available. * Minor cleanup. * test/rubygems: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44157 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-12* ext/bigdecimal/bigdecimal.c (VpSetPTR): fix for limitation of the resultingmrkn
precision. * test/bigdecimal/test_bigdecimal.rb (test_limit): add tests for the above change. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44153 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-12* doc/contributing.rdoc: [DOC] Fix typo in comments by @dvsuresh [Fixes GH-475]a_matsuda
* ext/openssl/ossl_ssl.c: ditto. * test/ruby/test_m17n.rb: ditto. https://github.com/ruby/ruby/pull/475 [ci-skip] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44148 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-12test_weakref.rb: use single level WeakRefnobu
* test/test_weakref.rb (make_weakref): return single level WeakRef, instead of multiple level, since the second level object may be still alive even after the final object get finalized, in test_recycled. * test/test_weakref.rb (test_ref): move living object assertions from test_recycled. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44146 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-11* eval.c (rb_raise_jump): call c_return hook immediately afterko1
popping `raise' frame. Patches by deivid (David Rodriguez). [Bug #8886] * test/ruby/test_settracefunc.rb: catch up this fix. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44139 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-11revert r44133. See https://bugs.ruby-lang.org/issues/8886 detailsko1
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44138 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-11hash.c: reject should return a plain hashnobu
* hash.c (rb_hash_reject): return a plain hash, without copying the class, default value, instance variables, and taintedness. they had been copied just by accident. [ruby-core:59045] [Bug #9223] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44137 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-11* eval.c (rb_raise_jump): pop frame after setup exception.ko1
Patches by deivid (David Rodriguez). [Bug #8886] * test/minitest/test_minitest_unit.rb: catch up this change. * test/ruby/test_backtrace.rb: ditto. * test/ruby/test_settracefunc.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44133 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-11envutil.rb: backtrace may not be presentnobu
* test/ruby/envutil.rb (assert_separately): SystemStackError at machine stack overflow on platforms where sigaltstack is unavailable does not have backtrace. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44130 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-10* lib/rubygems: Update to RubyGems master ec8ed22. Notable changesdrbrain
include: * Renamed extension_install_dir to extension_dir (backwards compatible). * Fixed creation of gem.deps.rb.lock file from TestGemRequestSet#test_install_from_gemdeps_install_dir * Fixed a typo and some documentation. * test/rubygems: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44129 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-10* insns.def: Fix optimization bug of Float#/ [Bug #9238]marcandre
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44127 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-10array.c, hash.c: add saltnobu
* array.c (rb_ary_hash): add salt to differentiate false and empty array. [ruby-core:58993] [Bug #9231] * hash.c (rb_any_hash, rb_hash_hash): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44125 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-10test_exception.rb: ignore SystemStackErrornobu
* test/ruby/test_exception.rb (test_machine_stackoverflow): ignore propagated SystemStackError, which has not bee rescued in the child process by unknown reason. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44124 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-10envutil.rb: ensure errorsnobu
* test/ruby/envutil.rb (assert_separately): dump error and assertions by END to ensure outputs even if failed to catch the raised exception. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44123 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-10openssl/digest.rb: get rid of deprecated classnobu
* ext/openssl/lib/openssl/digest.rb (digest, hexdigest): create new instance and call on it directly, to get rid of deprecated class OpenSSL::Digest::Digest. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44115 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-10gc.c: check arguments firstnobu
* gc.c (wmap_aset): check if both arguments are able to finalize before setting finalizers. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44108 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-10gc.c: fix WeakMap#inspectnobu
* gc.c (wmap_inspect_i): fix key/value order. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44107 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-10objspace_dump.c: include object's gc flags in dumptmm1
* ext/objspace/objspace_dump.c (dump_object): include fstring flag on strings. include gc flags (old, remembered, wb_protected) on all objects. * ext/objspace/objspace_dump.c (Init_objspace_dump): initialize lazy IDs before first use. * gc.c (rb_obj_gc_flags): new function to retrieve object flags * internal.h (RB_OBJ_GC_FLAGS_MAX): maximum flags allowed for one obj * test/objspace/test_objspace.rb (test_dump_flags): test for above * test/objspace/test_objspace.rb (test_trace_object_allocations): resolve name before dump (for rb_class_path_cached) git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44105 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-09vm_method.c: add new ruby::method-cache-clear dtrace probetmm1
* vm_method.c (rb_clear_method_cache_by_class): fire ruby::method-cache-clear probe on global or klass-level method cache clear [Bug #9190] * probes.d (provider ruby): new dtrace probe * doc/dtrace_probes.rdoc: docs for new probe * test/dtrace/test_method_cache.rb: test for new probe git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44103 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-09* compile.c, insns.def, test/ruby/test_rubyvm.rb, vm.c, vm_core.h,charliesome
vm_insnhelper.c, vm_insnhelper.h, vm_method.c: Rename method_serial to global_method_state and constant_serial to global_constant_state after discussion with ko1. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44097 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-09hash.c: fix segv in Hash#replacetmm1
* hash.c (rb_hash_replace): fix segv on `{}.replace({})` introduced in r44060 [Bug #9230] [ruby-core:58991] * test/ruby/test_hash.rb: regression test for above git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44096 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-09gc.c: ObjectSpace::WeakMap#sizenobu
* gc.c (wmap_size): add ObjectSpace::WeakMap#size and #length. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44093 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-09test_weakmap.rb: addnobu
* test/ruby/test_weakmap.rb: test for ObjectSpace::WeakMap. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44092 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-09removed.shugo
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44090 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-08* lib/rubygems: Update to RubyGems master bf37240. Fixes uselessdrbrain
error message with `gem install -g` with no gem dependencies file. * test/rubygems: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44085 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-08* lib/rubygems: Update to RubyGems master 096db36. Changes includedrbrain
support for PATH in Gemfile.lock and a typo fix from Akira Matsuda. * test/rubygems: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44081 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-08hash.c: reject shoult infectnobu
* hash.c (rb_hash_reject): result should be infected by the receiver. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44074 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-08* bigdecimal.c (BigDecimal_coerce): convert a Float to a BigDecimal insteadmrkn
of converting the receiver to a Float. [ruby-core:58756] [Bug #9192] * test/bigdecimal/test_bigdecimal.rb: add tests for the above change. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44073 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-08class.c, vm_insnhelper.c: check unknown keywordsnobu
* class.c (rb_get_kwargs): if optional is negative, unknown keywords are allowed. * vm_insnhelper.c (vm_callee_setup_keyword_arg): check unknown keywords. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44069 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-08test_keyword.rb: check error messagesnobu
* test/ruby/test_keyword.rb (test_required_keyword): check also error messages. * test/ruby/test_keyword.rb (test_block_required_keyword): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44067 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-08* array.c (rb_ary_shuffle_bang, rb_ary_sample): checkktsj
unknown keywords. * test/ruby/test_array.rb (test_shuffle, test_sample): tests for the above. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44064 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-08vm.c: add RubyVM.stat for accessing cache serialstmm1
* vm.c (ruby_vm_stat): add RubyVM.stat() for access to internal cache counters. this methods behaves like GC.stat, accepting an optional hash or symbol argument. [Bug #9190] [ruby-core:58750] * test/ruby/test_rubyvm.rb: test for new method git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44062 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-08hash.c: revert r43870 and add alternative parser patch for literal keystmm1
* hash.c (hash_aset_str): revert r43870 due to performance issue [Bug #9188] [ruby-core:58730] * parse.y (assoc): convert literal string hash keys to fstrings * test/ruby/test_hash.rb (class TestHash): expand test git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44058 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-08parse.y: use rb_fstring() for strings stored in the symbol tabletmm1
* parse.y (register_symid_str): use fstrings in symbol table [Bug #9171] [ruby-core:58656] * parse.y (rb_id2str): ditto * string.c (rb_fstring): create frozen_strings on first usage. this allows rb_fstring() calls from the parser (before cString is created) * string.c (fstring_set_class_i): set klass on fstrings generated before cString was defined * string.c (Init_String): convert frozen_strings table to String objects after boot * ext/-test-/symbol/type.c (bug_sym_id2str): expose rb_id2str() * test/-ext-/symbol/test_type.rb (module Test_Symbol): verify symbol table entries are fstrings git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44057 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-08* lib/rubygems: Update to RubyGems master 14749ce. This fixes bugsdrbrain
handling of gem dependencies lockfiles (Gemfile.lock). * test/rubygems: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44054 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-07hash.c: rb_hash_reject without dupnobu
* hash.c (rb_hash_reject): copy unrejected elements only to new hash, so that the change on the original receiver can affect. [ruby-core:58914] [Bug #9223] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44047 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-07test_struct.rb: use assert_samenobu
* test/ruby/test_struct.rb (test_question_mark_in_member): true value has no meanings itself. use assert_same instead. * test/ruby/test_struct.rb (test_bang_mark_in_member): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44046 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-07test_struct.rb: use assert_predicatenobu
* test/ruby/test_struct.rb (test_question_mark_in_member): assert_true is a method in test-unit. use assert_predicate instead. * test/ruby/test_struct.rb (test_bang_mark_in_member): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44045 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-12-06* test/ruby/test_struct.rb: Add regression test for question marks andcharliesome
bangs in struct members. [Closes GH-468] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44042 b2dd03c8-39d4-4d8f-98ff-823fe69b080e