summaryrefslogtreecommitdiff
path: root/test
AgeCommit message (Collapse)Author
2019-07-30Use lowercase letters for IPv6 addresses.Tanaka Akira
Reported by chucke (Tiago Cardoso). Patch by jeremyevans0 (Jeremy Evans). [Bug #14612]
2019-07-29Revert "Do not always taint the result of File#path"Jeremy Evans
This reverts commit 1a759bfe5d554c22571d2e6e4e5998cf06a7b98f. This fails on some operating systems.
2019-07-29Do not always taint the result of File#pathJeremy Evans
The result should only be tainted if the path given to the method was tainted. The code to always taint the result was added in a4934a42cbb84b6679912226581c71b435671f55 (svn revision 4892) in 2003 by matz. However, the change wasn't mentioned in the commit message, and it may have been committed by accident. Skip part of a readline test that uses Reline. Reline in general would pass the test, but Reline's test mode doesn't raise a SecurityError if passing a tainted prompt and $SAFE >= 1. This was hidden earlier because File#path was always returning a tainted string. Fixes [Bug #14485]
2019-07-29Warn if using return at top-level with an argumentJeremy Evans
Fixes [Bug #14062]
2019-07-29Removed unused variables and methodsNobuyoshi Nakada
2019-07-29[ruby/rdoc] Removed unused variableNobuyoshi Nakada
2019-07-27Occupy match dataNobuyoshi Nakada
* string.c (rb_str_split_m): occupy match data not to be modified during yielding the block. [Bug #16024]
2019-07-27Initialize DST flagNobuyoshi Nakada
* time.c (zone_timelocal): initialize DST flag by asking the timezone object. [Bug #15988]
2019-07-26Test SecureRandom.uuid formatJeremy Evans
SecureRandom uses v4 UUIDs, which are completely random except for 6 bits, 4 in the version field and 2 in the clk_seq_hi_res field. Add a test that those bit patterns are set correctly for v4 UUIDs, per RFC 4122 section 4.4. Fixes [Bug #13603]
2019-07-26Document and add spec for delegating to constants in ForwardableJeremy Evans
Fixes [Bug #13142]
2019-07-26[ruby/rdoc] Support nesting text page URLaycabta
RDoc::Servlet#documentation_page replaces "/" in URL with "::" for class or module but it's also used for the replaced name on text pages. This causes a bug when text pages are in nesting directory. This commit fixes #615. https://github.com/ruby/rdoc/commit/d73b915b1e
2019-07-26[ruby/rdoc] Normalization of comment should check languageaycabta
RDoc::Text#normalize_comment that is included RDoc::Comment always remove Ruby style comment indicator "#" and C style comment indicator "/**/", but should check language and remove only the language's comment indicator. https://github.com/ruby/rdoc/commit/ca68ba1e73
2019-07-26[ruby/rdoc] ClassModule#add_comment should receive RDoc::Commentaycabta
https://github.com/ruby/rdoc/commit/3fb03bf399
2019-07-25Separated tool/test/runner.rb and test/runner.rbNobuyoshi Nakada
As `make test-tool` does not use gems, and no Rubygems stuffs is needed, so moved such things to test/runner.rb. Also no longer nees `--test-target-dir` option.
2019-07-25[ruby/psych] Suppress uninitialized instance variable warningsNobuyoshi Nakada
In verbose mode, `test_delegator` in `test/psych/visitors/test_yaml_tree.rb` shows following warning. https://travis-ci.org/ruby/psych/jobs/562435717#L268 ``` /home/travis/build/ruby/psych/test/psych/visitors/test_yaml_tree.rb:10: warning: instance variable @obj not initialized ``` This is because `Psych.load` bypasses #initialize with the #init_with method. https://github.com/ruby/psych/commit/f99523388f
2019-07-25[ruby/psych] Deduplicate hash keys if they're stringsJean Boussier
https://github.com/ruby/psych/commit/0414982ffd
2019-07-25Fix errno at seeking socket/pipe on WindowsNobuyoshi Nakada
[Bug #12230]
2019-07-24Suppress deflateParams() warningsNobuyoshi Nakada
2019-07-24[rubygems/rubygems] Make `@@project_dir` constants per filesNobuyoshi Nakada
https://github.com/rubygems/rubygems/commit/955174658f
2019-07-24[rubygems/rubygems] Resolve `@@project_dir` from test file pathsNobuyoshi Nakada
`Dir.pwd` may differ from the source path. Test directories and files should be resolved from test file paths. https://github.com/rubygems/rubygems/commit/e18e7c81b4
2019-07-24should not free local hook_list here.Koichi Sasada
exec_hooks_postcheck() clean executed hook_list if it is needed. list_exec is freed if there are no events and this list is local event (connected to specific iseq). However, iseq keeps to point this local hook_list, freed list. To prevent this situation, do not free hook_list here even if it has no events. This issue is reported by @joker1007. https://twitter.com/joker1007/status/1153649170797830144
2019-07-23Make Object#singleton_methods work correctly for singleton classes of objectsJeremy Evans
Fixes [Bug #10901]
2019-07-24Test missing Content-Type warningsNobuyoshi Nakada
2019-07-24Test invalid offset warningsNobuyoshi Nakada
2019-07-24Show the caller's locationNobuyoshi Nakada
* lib/net/http/header.rb: show the caller's location instead of the current lines.
2019-07-23Split test/ripper/test_files.rb to run in parallelNobuyoshi Nakada
2019-07-21tool/test/runner.rb: support --test-target-dir optionYusuke Endoh
tool/test/runner.rb had been copied from test/runner.rb. test/runner.rb was for `make test-all`, and tool/test/runner.rb was for `make test-testframework` and `make test-tool`. But I want to avoid the code clones. This change makes tool/test/runner.rb support --test-target-dir option which allows tool/test/runner.rb to run `make test-all`. Now we can remove test/runner.rb.
2019-07-16Allow mday in Date.iso8601 to be omittedNobuyoshi Nakada
[Bug #12285]
2019-07-15Removed duplicate highlightingNobuyoshi Nakada
2019-07-15Move helper file of logger to under the test/logger.Hiroshi SHIBATA
2019-07-15[ruby/logger] Add option to set the binary mode of the log deviceRafael Mendonça França
Without binmode strings with incompatible encoding can't be written in the file. This is very common in applications that log user provided parameters. We need to allow changing the binnary mode because right now it is impossible to use the built-in log rotation feature when you provide a File object to the LogDevice, and if you provide a filename you can't have binmode. https://github.com/ruby/logger/commit/9114b3ac7e
2019-07-15[ruby/logger] Set filename when initializing logger with a File objectJeremy Evans
This should allow reopen to work. Requested in ruby issue #14595. https://github.com/ruby/logger/commit/bd367aff12
2019-07-15[ruby/logger] Fix to use logger and test-unit in this repo withsonots
`ruby test/logger/test_xxx.rb` https://github.com/ruby/logger/commit/d3c2402340
2019-07-15[ruby/logger] Add support for changing severity using bang methods.Samuel Williams
https://github.com/ruby/logger/commit/ae4c6dfcbb
2019-07-15add tests for orphan/not-orphan proc/lambda.Tanaka Akira
2019-07-15add tests for "break" in lambda.Tanaka Akira
2019-07-15Move a test file of Reline to test/reline/aycabta
2019-07-15The default charset of text/* media type is UTF-8.Tanaka Akira
Thanks for the patch gareth (Gareth Adams). [Bug #15933] ------- Combines two small, but very related changes 1: Treat HTTPS the same as HTTP Previously, OpenURI followed guidance in RFC2616/3.7.1: > When no explicit charset parameter is provided by the sender, media > subtypes of the "text" type are defined to have a default charset > value of "ISO-8859-1" when received via HTTP. However this RFC was written before TLS was established and OpenURI was never updated to treat HTTPS traffic the same way. So, HTTPS documents received a different default to HTTP documents. This commit removes the scheme check so that all text/* documents processed by OpenURI are treated the same way. In theory this processing gets applied to FTP URIs too, but there's no mechanism in OpenURI for FTP documents to have Content-Type metadata appended to them, so this ends up being a no-op. 2: Change default charset for text/* to UTF-8 Replaces the default ISO-8859-1 charset previously defined in RFC2616 (now obsoleted) with a UTF-8 charset as defined in RFC6838. Fixes: https://bugs.ruby-lang.org/issues/15933
2019-07-15Remove unused method.manga_osyo
2019-07-15Rename to Reline::History::Test.manga_osyo
2019-07-15Add `class Reline::History` and test.manga_osyo
2019-07-14[ruby/csv] Fix a bug that strip: true removes newlinesKouhei Sutou
https://github.com/ruby/csv/commit/5540d35a30
2019-07-14[ruby/csv] Don't raise on eof?Kouhei Sutou
GitHub: fix #86 Reported by krororo. Thanks!!! https://github.com/ruby/csv/commit/5a8d9d9297
2019-07-14Check the result of String#-@Nobuyoshi Nakada
2019-07-14MJIT Support for getblockparamproxyTakashi Kokubun
2019-07-14Fix links to headingsMaxime Lapointe
A previous change made the header's id be fully referenced (for the sidebar I believe) but this broke links to them. This fixes the issue.
2019-07-14Delegates 3 arguments for Pathname.glob.Tanaka Akira
Thanks for the patch by pocke (Masataka Kuwabara) [Feature #14405].
2019-07-14Warn open-uri's "open" method at Kernel.Tanaka Akira
Use URI.open instead. Thanks for the patch by jeremyevans0 (Jeremy Evans) [Misc #15893].
2019-07-14Method#inspect with source location.Koichi Sasada
Method#inspect shows with source location. [Feature #14145]
2019-07-14add encoding conversion from/to CESU-8Martin Dürst
Add encoding conversion (transcoding) from UTF-8 to CESU-8 and back. CESU-8 is an encoding similar to UTF-8, but encodes codepoints above U+FFFF as two surrogates, these surrogates again being encoded as if they were UTF-8 codepoints. This preserves the same binary sorting order as in UTF-16. It is also somewhat similar (although not exactly identical) to an encoding used internally by Java. This completes issue #15995. enc/trans/cesu_8.trans: Add encoding conversion from/to CESU-8 test/ruby/test_transcode.rb: Add tests for above