summaryrefslogtreecommitdiff
path: root/spec/ruby
AgeCommit message (Collapse)Author
2020-01-09Include the standard `id` command outputNobuyoshi Nakada
On macOS, GNU coreutils `id` is limited to NGROUPS_MAX groups, because of the backward compatibility of getgroups(2).
2020-01-03Make eval(code, binding) use (eval) as __FILE__ and 1 as __LINE__Jeremy Evans
This removes the warning that was added in 3802fb92ff8c83eed3e867db20f72c53932f542d, and switches the behavior so that the eval does not use the binding's __FILE__ and __LINE__ implicitly. Fixes [Bug #4352] Notes: Merged: https://github.com/ruby/ruby/pull/2816
2020-01-02Update specs for keyword argument separationJeremy Evans
Notes: Merged: https://github.com/ruby/ruby/pull/2794
2019-12-30MinGW on Actions (#2791)MSP-Greg
* MinGW - skip spec in spec/ruby/optional/capi/thread_spec.rb C-API Thread function rb_thread_call_without_gvl -- runs a C function with the global lock unlocked and unlocks IO with the generic RUBY_UBF_IO stops/freezes spec tests See https://bugs.ruby-lang.org/issues/16265 * MinGW - skip test test/resolv/test_dns.rb Test times out in CI (both AppVeyor & Actions), cannot repo locally * MinGW - skip test test/ruby/test_thread_queue.rb * Add Actions mingw.yml
2019-12-30Fix Proc#<< specAlan Wu
[Bug #16406]
2019-12-30Decide lambdaness of (f << g) using g (#2729)Alan Wu
* Deciding lambdaness of (f << g) using g * Use version guards for spec changes Notes: Merged-By: XrXr
2019-12-27Update to ruby/spec@7241f39Benoit Daloze
2019-12-27Update to ruby/spec@d419e74Benoit Daloze
2019-12-24Get rid of false positive misspellingsNobuyoshi Nakada
[Bug #16437]
2019-12-23Revert "Should return "." for File.extname("file.") also on Windows"NAKAMURA Usaku
We want to introduce consistency and better compatibility with unixen, but the Windows APIs doues not have consistency fundamentally and we can not found any logical way... This reverts commit 61aff0cd189e67fa6f2565639ad0128fa33b88fc.
2019-12-22Move version guard outside to make it clear the method was added in Ruby 2.5Benoit Daloze
2019-12-22Should return "." for File.extname("file.") also on WindowsNAKAMURA Usaku
But not changes another cases, such as "file.rb." [Bug #15267]
2019-12-21Add spec for capturing Kernel#lambda with Kernel#methodAlan Wu
Notes: Merged: https://github.com/ruby/ruby/pull/2289
2019-12-21Add specs for calling into Kernel#lambda with superAlan Wu
Notes: Merged: https://github.com/ruby/ruby/pull/2289
2019-12-20Makes the receiver to FrozenError.new a keyword parameterNobuyoshi Nakada
[Feature #16419]
2019-12-20Fixed misspellingsNobuyoshi Nakada
Fixed misspellings reported at [Bug #16437], only in ruby and rubyspec.
2019-12-17close datasocket on stor of server sideNARUSE, Yui
2019-12-11Test `Thread#to_s` when used from to_s_spec.rbNobuyoshi Nakada
2019-12-11`Thread#to_s` has been added at ruby 2.5Nobuyoshi Nakada
2019-12-11Thread#to_s is not same as #inspect on old version.Koichi Sasada
Thread#to_s returns simple Object#to_s until Ruby 2.4.
2019-12-11fix for old MRI versionsKoichi Sasada
2019-12-11Make Thread#to_s consistent with Method and Proc to_sJean byroot Boussier
Notes: Merged: https://github.com/ruby/ruby/pull/2738
2019-12-04Revert "Regexp#match{?} with nil raises TypeError as String, Symbol (#1506)"NARUSE, Yui
This reverts commit 2a22a6b2d8465934e75520a7fdcf522d50890caf. Revert [Feature #13083]
2019-12-04Revert "Revert nil error and adding deprecation message"NARUSE, Yui
This reverts commit 452bee3ee8d68059fabd9b1c7a75661b14e3933e.
2019-12-04Revert "Improve warning message"NARUSE, Yui
This reverts commit 31110d820cc1258cbc84b46ecc65b254c7d5529a.
2019-12-04Revert "Fix warnings in Regexp#{match,match?} specs"NARUSE, Yui
This reverts commit 782d1b8fb0a039cedef9ad9c94f432dad51901e6.
2019-12-02Make more attempts to check for the precision of Process.timesBenoit Daloze
* Process.clock_getres specs use 10_000 but that's quite slow for the Process.times spec.
2019-12-02Fix random failure on getusage-missing environmentsTakashi Kokubun
`* 1e6` makes a spurious result about floating point number's precision. ``` irb(main)[01:0]> 16.028 => 16.028 irb(main)[02:0]> (16.028 * 1e6) => 16027999.999999998 ```
2019-12-01Debug random failure of ruby-spec on ci.rvm.jpTakashi Kokubun
2019-12-01Update to ruby/spec@dcf4955Benoit Daloze
2019-12-01[ruby/spec] Fix failures with LC_ALL=CNobuyoshi Nakada
https://github.com/ruby/spec/commit/51047687c0 https://github.com/ruby/spec/commit/2b87b467cc
2019-12-01Fixed type of an index variableNobuyoshi Nakada
2019-11-30Skip if getrusage is not supportedTakashi Kokubun
1243255c3a36433041012b6107a5ac48658a0895 broke ci.rvm.jp tests like http://ci.rvm.jp/results/trunk_clang_39@silicon-docker/2445098. 253232c028a5565dbeecc05fab5e81b35ab58bcc works only if getrusage is supported.
2019-11-30Update to ruby/spec@4eec3dcBenoit Daloze
2019-11-29check interrupts at each frame pop timing.Koichi Sasada
Asynchronous events such as signal trap, finalization timing, thread switching and so on are managed by "interrupt_flag". Ruby's threads check this flag periodically and if a thread does not check this flag, above events doesn't happen. This checking is CHECK_INTS() (related) macro and it is placed at some places (laeve instruction and so on). However, at the end of C methods, C blocks (IMEMO_IFUNC) etc there are no checking and it can introduce uninterruptible thread. To modify this situation, we decide to place CHECK_INTS() at vm_pop_frame(). It increases interrupt checking points. [Bug #16366] This patch can introduce unexpected events...
2019-11-18Deprecate taint/trust and related methods, and make the methods no-opsJeremy Evans
This removes the related tests, and puts the related specs behind version guards. This affects all code in lib, including some libraries that may want to support older versions of Ruby. Notes: Merged: https://github.com/ruby/ruby/pull/2476
2019-11-18Warn on access/modify of $SAFE, and remove effects of modifying $SAFEJeremy Evans
This removes the security features added by $SAFE = 1, and warns for access or modification of $SAFE from Ruby-level, as well as warning when calling all public C functions related to $SAFE. This modifies some internal functions that took a safe level argument to no longer take the argument. rb_require_safe now warns, rb_require_string has been added as a version that takes a VALUE and does not warn. One public C function that still takes a safe level argument and that this doesn't warn for is rb_eval_cmd. We may want to consider adding an alternative method that does not take a safe level argument, and warn for rb_eval_cmd. Notes: Merged: https://github.com/ruby/ruby/pull/2476
2019-11-12Show the name `Kernel#proc` in the warning messageNobuyoshi Nakada
2019-11-09Removed trial and errorsNobuyoshi Nakada
2019-11-09Specify the permissionNobuyoshi Nakada
To make the temporary directory non-writable by group and others.
2019-11-09Fixed the debug printNobuyoshi Nakada
2019-11-09Debug-print tmpdir infoNobuyoshi Nakada
2019-11-09Add debug printKazuhiro NISHIYAMA
2019-11-09Try to fix test-spec failure on macOSYusuke Endoh
Not sure what is happening, but spec/ruby/security/cve_2018_6914_spec.rb fails on macOS. https://github.com/ruby/ruby/runs/294462511#step:10:134 I suspect that the state of a directory is weird immediately after it is created (not writable or even world writable?). This change tries to make sure that ENV["TMPDIR"] is actually used by Dir.tmpdir.
2019-11-06Exclude some clocks on armv8 tooBenoit Daloze
* See https://bugs.ruby-lang.org/issues/16234#note-16
2019-11-06Fix spawn_spec.rb for Travis arm64 environment.Jun Aruga
The process group id (/proc/[pid]/stat 5th field) is 0 in the Travis arm64 environment. This is a case where it is available. $ cat /proc/4543/stat 4543 (ruby) S 4525 4525 1384 34818 4525 4194304 37443 1754841 0 0 366 105 2291 391 20 0 3 0 1381328 1428127744 11475 18446744073709551615 94195983785984 94195986670225 140728933833312 0 0 0 0 0 1107394127 0 0 0 17 2 0 0 1 0 0 94195987686512 94195987708942 94196017770496 140728933835483 140728933835595 140728933835595 140728933842904 0 This is a case where it is not available in Travis arm64 environment. $ cat /proc/19179/stat 19179 (ruby) S 19160 0 0 0 -1 4194560 37618 1710547 313 163 770 665 5206 1439 20 0 2 0 17529566 1196347392 10319 18446744073709551615 187650811428864 187650815023116 281474602721280 0 0 0 0 4096 1107390031 0 0 0 17 22 0 0 0 0 0 187650815091456 187650815114064 187651414974464 281474602725080 281474602725211 281474602725211 281474602729420 0 See "man proc" for detail. Notes: Merged: https://github.com/ruby/ruby/pull/2653
2019-11-05Revert "[EXPERIMENTAL] Make Symbol#to_s return a frozen String [Feature #16150]"NARUSE, Yui
This reverts commit 6ffc045a817fbdf04a6945d3c260b55b0fa1fd1e.
2019-11-03Fix warnings in Regexp#{match,match?} specsBenoit Daloze
2019-11-03Improve warning messageKenichi Kamiya
https://github.com/ruby/ruby/pull/2637#discussion_r341812475
2019-11-03Revert nil error and adding deprecation messageKenichi Kamiya
Notes: Merged: https://github.com/ruby/ruby/pull/2637