aboutsummaryrefslogtreecommitdiffstats
path: root/test
Commit message (Collapse)AuthorAgeFilesLines
* vm.c: fix return in lambdanobu2016-12-311-0/+20
| | | | | | | | | * vm.c (invoke_block_from_c_splattable): pass lambda-ness. * vm_eval.c (yield_under): invoke lambda proc properly. [ruby-core:78917] [Bug #13090] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57240 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* rational.c: memory leak in gcdnobu2016-12-301-0/+10
| | | | | | | | * rational.c (rb_gcd_gmp): fix memory leak. patched by KISHIMOTO, Makoto <ksmakoto AT dd.iij4u.or.jp> in [ruby-dev:49934]. [Bug #13089] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57236 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test/ruby/test_pack.rb: fix test case added by r57187rhe2016-12-291-1/+1
| | | | | | | | | | | | The test case for String#unpack added by r57187 is not properly testing because the String will be filled after the block invocation. [ruby-core:78841] [Bug #13075] Thanks to nagachika for pointing this out: http://d.hatena.ne.jp/nagachika/20161226/ruby_trunk_changes_57184_57194#r57187 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57234 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* rational.c: fix for mathnnobu2016-12-291-0/+9
| | | | | | | * rational.c (read_num, read_rat_nos): dispatch by the type of numerator, for mathn. [ruby-core:78893] [Bug #13084] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57232 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* numeric.c: reduce fdivnobu2016-12-281-0/+7
| | | | | | | * numeric.c (rb_int_fdiv_double): reduce first for more precise result. [ruby-core:78886] [Bug #13078] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57227 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* io.c: ARGF fd leaknobu2016-12-271-1/+7
| | | | | | | * io.c (argf_next_argv): fix leak of fd after breaking in #each method. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57203 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* io.c: fix race between read and closenobu2016-12-261-0/+30
| | | | | | | | * io.c (io_fillbuf): fix race between read and close, in the case the IO gets closed before the reading thread achieve the lock. [ruby-core:78845] [Bug #13076] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57199 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y: preserve cmdarg stacknobu2016-12-261-0/+9
| | | | | | | * parse.y (do_body): preserve cmdarg stack around do/end block. [ruby-core:78837] [Bug #13073] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57198 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* vm_eval.c: Symbol#to_proc and instance_execnobu2016-12-261-0/+6
| | | | | | | * vm_eval.c (yield_under): should evaluate the proc on the first argument. [ruby-core:78839] [Bug #13074] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57194 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test/ruby/test_symbol.rb: use begin;end; hacknobu2016-12-261-9/+18
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57193 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* pack.c: avoid returning uninitialized Stringrhe2016-12-261-0/+8
| | | | | | | | | | Fix unpacking with 'b', 'B', 'h' and 'H' format. Do not return an uninitialized String to Ruby before filling the content bytes. Fixes r11175 ("pack.c (pack_unpack): execute block if given with unpacked value instead of creating an array", 2006-10-15). [ruby-core:78841] [Bug #13075] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57187 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* string.c: CRLF in paragraph modenobu2016-12-251-0/+10
| | | | | | | * string.c (rb_str_enumerate_lines): allow CRLF to separate paragraphs. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57185 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* string.c: consistent paragraph mode with IOnobu2016-12-251-6/+6
| | | | | | | | * string.c (rb_str_enumerate_lines): in paragraph mode, do not include newlines which separate paragraphs, so that it will be consistent with IO#each_line. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57184 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test/unit.rb: restore parallel optionnobu2016-12-241-0/+2
| | | | | | | * test/lib/test/unit.rb (_run_parallel): restore parallel option after retrying for --repeat-count option. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57169 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test/unit.rb: --subprocess-timeout-scale optionnobu2016-12-242-0/+24
| | | | | | | | | | * test/lib/envutil.rb (EnvUtil#invoke_ruby): add subprocess timeout scaling factor. * test/lib/test/unit.rb (Test::Unit::SubprocessOption): add --subprocess-timeout-scale option. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57168 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test/unit.rb: --repeat-count optionnobu2016-12-242-13/+40
| | | | | | | * test/lib/test/unit.rb (Test::Unit::RepeatOption): --repeat-count option to repeat COUNT times while success. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57167 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Increase timeoutnaruse2016-12-231-1/+1
| | | | | | http://rubyci.org/logs/rubyci.s3.amazonaws.com/aix71_ppc/ruby-trunk/log/20161223T113301Z.fail.html.gz git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57160 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* assertions.rb: prepare_syntax_checknobu2016-12-231-22/+17
| | | | | | | | * test/lib/test/unit/assertions.rb (prepare_syntax_check): extract common preparation of arguments from assert_valid_syntax and assert_syntax_error. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57159 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* assertions.rb: syntax check by iseqnobu2016-12-231-14/+6
| | | | | | | | | | | * test/lib/test/unit/assertions.rb (assert_valid_syntax): use RubyVM::InstructionSequence.compile to get rid of executing the code, instead of catch&throw. sample/trick2015/kinaba/entry.rb no longer raises an Invalid return. * test/lib/test/unit/assertions.rb (assert_syntax_error): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57158 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_modify_expand.rb: skip if no overflownobu2016-12-221-0/+1
| | | | | | | | * test/-ext-/string/test_modify_expand.rb (test_integer_overflow): no longer happens on platforms where size_t is larger than long, e.g. 64bit windows, since r57122. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57156 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_float.rb: add test cases for Float#roundyui-knk2016-12-221-0/+21
| | | | | | | * test_float.rb: add test cases for Float#round with half nil. Follow up r57130. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57151 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_rinda.rb: ipv6_mcnobu2016-12-221-25/+25
| | | | | | | * test/rinda/test_rinda.rb (RingIPv6#ipv6_mc): extract IPv6 multicast setup and cleanup, and ignore ENETDOWN. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57147 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* bigdecimal: version 1.3.0mrkn2016-12-211-1/+39
| | | | | | | | Import bigdecimal version 1.3.0. The full commit log is here: https://github.com/ruby/bigdecimal/compare/v1.3.0.pre.2...v1.3.0 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57145 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* time.c: refine num_exact error messagenobu2016-12-211-0/+10
| | | | | | | * time.c (num_exact): show the original argument when conversion failed, instead of intermediate nil. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57140 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* eval.c: fix circular causenobu2016-12-211-0/+20
| | | | | | | * eval.c (exc_setup_cause): always set cause of cause to get rid of circular references. [ruby-core:78688] [Bug #13043] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57137 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* compile.c: toplevel returnnobu2016-12-211-0/+23
| | | | | | | * compile.c (iseq_compile_each): stop execution of the current source by toplevel return. [ruby-core:36785] [Feature #4840] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57132 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* numeric.c: allow nil as rounding mode optionnobu2016-12-211-2/+2
| | | | | | | * numeric.c (rb_num_get_rounding_option): allow nil same as the default behavior, per [ruby-core:77961]. [Bug #12548] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57130 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* suppress warning: attempt to close unfinished zstream; reset forced.naruse2016-12-201-1/+3
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57127 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Zlib.gzip uses kwargs instead of argc [Feature #13020]naruse2016-12-201-3/+3
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57126 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* io.c: update argf linenonobu2016-12-201-7/+10
| | | | | | | * io.c (argf_rewind): rewind line number in non-global ARGF instance. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57125 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* io.c: update argf linenonobu2016-12-201-0/+12
| | | | | | | * io.c (argf_block_call_line): update line number in non-global ARGF instance. [ruby-core:78728] [Bug #13051] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57124 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* re.c: consider the case of RMatch::regexp is nilrhe2016-12-201-3/+19
| | | | | | | | Follow r49675, r57098 and r57110. Don't assume RMatch::regexp always contains a valid Regexp instance; it will be Qnil if the MatchData is created by rb_backref_set_string(). [ruby-core:78741] [Bug #13054] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57123 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* array.c: do not resize to less than 0rhe2016-12-201-0/+5
| | | | | | | | | Shrinking the Array from the block invoked by Array#select! or Array#reject! causes the Array to be a negative number size. Ensure that the resulting Array won't be smaller than 0. [ruby-core:78739] [Bug #13053] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57121 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* array.c: check array length every time after yieldingrhe2016-12-201-3/+10
| | | | | | | | | | | Since the Array may be modified during rb_yield(), the length before invoking the block can't be trusted. Fix possible out-of-bounds read in Array#combination and Array#repeated_combination. It may better to make a defensive copy of the Array, but for now let's follow what Array#permutation does. [ruby-core:78738] [Bug #13052] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57119 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test/unit.rb: separator [ci skip]nobu2016-12-201-0/+1
| | | | | | | * test/lib/test/unit.rb (ExcludesOption#setup_options): add separator for --excludes-dir in help message. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57116 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Increase timeoutnaruse2016-12-181-3/+3
| | | | | | http://rubyci.s3.amazonaws.com/unstable10s/ruby-trunk/log/20161215T021909Z.fail.html.gz git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57109 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* sprintf.c: fix width underflownobu2016-12-171-0/+5
| | | | | | | * sprintf.c (rb_str_format): fix memory corruption by width underflow. https://github.com/mruby/mruby/issues/3347 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57108 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Increase timeoutnaruse2016-12-171-1/+1
| | | | | | http://rubyci.org/logs/13.78.52.201/vc12-x64/ruby-trunk/log/20161217T103523Z.log.html.gz git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57106 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_mailto.rb: overwritten methodsnobu2016-12-171-6/+4
| | | | | | | * test/uri/test_mailto.rb (URI::TestMailTo#test_to_mailtext): merge overwritten methods. [Bug #10774] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57100 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_mailto.rb: adjust scopenobu2016-12-171-10/+4
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57099 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* re.c: non-regexp name referencenobu2016-12-171-0/+4
| | | | | | | * re.c (rb_reg_regsub): other than regexp has no name references. [ruby-core:78686] [Bug #13042] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57098 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* multiline heredoc identifiernobu2016-12-161-1/+1
| | | | | | | * parse.y (parser_heredoc_identifier): reject multiline here document identifier, which never matches single line. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57089 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* fix chomping newline only linenobu2016-12-161-0/+12
| | | | | | | | | * string.c (chomp_newline): fix chomping newline only line. rb_enc_prev_char return NULL if no previous character and must not call rb_enc_ascget on it. a patch by Ary Borenszweig <asterite AT gmail.com> at [ruby-core:78666]. [Bug #13037] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57088 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y: newline in heredoc identifiernobu2016-12-151-0/+6
| | | | | | | * parse.y (parser_heredoc_identifier): warn newline in here document identifier. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57085 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Removed the obstacle to running test-all with VC14.usa2016-12-141-2/+2
| | | | | | | | * test/fiddle/test_import.rb (LIBC.fprintf): VC14's `fprintf` is very distinct name, then, just ignore this test. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57081 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* encoding.c: handle needmore error from rb_enc_precise_mbclen()rhe2016-12-141-0/+4
| | | | | | | | | | | | rb_enc_ascget() erroneously reports success even if the given byte sequence is incomplete, for non-ASCII compatible encoding strings. rb_enc_precise_mbclen() may return a negative value on error, and thus rb_enc_ascget() must not store the return value in 'unsigned int'; otherwise the subsequent MBCLEN_CHARFOUND_P() check won't catch the error. [ruby-core:78646] [Bug #13034] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57078 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y: fix yyerror messagenobu2016-12-141-0/+5
| | | | | | | * parse.y (parser_yyerror): show the error line even if the error is at the end. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57073 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Use URI.decode_www_form_component [Bug #10774]naruse2016-12-121-0/+6
| | | | | | | `parser` refered RFC2396_Parser, but it is separated. test is contributed by Dominik Menke git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57066 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test for Symbol#match? [Feature #12898]nobu2016-12-121-0/+42
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57055 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_m17n.rb: escapenobu2016-12-121-4/+4
| | | | | | | * test/ruby/test_m17n.rb (test_regexp_ascii_none): escape regexp meta characters. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57054 b2dd03c8-39d4-4d8f-98ff-823fe69b080e