summaryrefslogtreecommitdiff
path: root/spec/ruby/core
AgeCommit message (Collapse)Author
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-12Show the name `Kernel#proc` in the warning messageNobuyoshi Nakada
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
2019-10-26Update to ruby/spec@28a728bBenoit Daloze
2019-10-17Fixed File.extname at a name ending with a dotNobuyoshi Nakada
File.extname now returns a dot string at a name ending with a dot. [Bug #15267] Notes: Merged: https://github.com/ruby/ruby/pull/2565
2019-10-17* remove trailing spaces. [ci skip]git
2019-10-17Regexp#match{?} with nil raises TypeError as String, Symbol (#1506)Kenichi Kamiya
* {String|Symbol}#match{?} with nil returns falsy To improve consistency with Regexp#match{?} * String#match(nil) returns `nil` instead of TypeError * String#match?(nil) returns `false` instead of TypeError * Symbol#match(nil) returns `nil` instead of TypeError * Symbol#match?(nil) returns `false` instead of TypeError * Prefer exception * Follow empty ENV * Drop outdated specs * Write ruby/spec for above https://github.com/ruby/ruby/pull/1506/files#r183242981 * Fix merge miss
2019-10-16Comparable#clamp with a range [Feature #14784]Nobuyoshi Nakada
Notes: Merged: https://github.com/ruby/ruby/pull/2556
2019-10-14Suppress warnings for Thread.exclusiveNobuyoshi Nakada
2019-09-29Update to ruby/spec@34e6246Benoit Daloze
2019-09-29Update to ruby/spec@e69a14cBenoit Daloze
2019-09-29Update to ruby/spec@519df35Benoit Daloze
2019-09-27[EXPERIMENTAL] Make NilClass#to_s, TrueClass#to_s and FalseClass#to_s return ↵Jean Boussier
a frozen String * Always the same frozen String for each of these values. * Avoids extra allocations whenever calling these 3 methods. * See [Feature #16150] Notes: Merged: https://github.com/ruby/ruby/pull/2492
2019-09-26[EXPERIMENTAL] Make Module#name return a frozen StringJean Boussier
* Always the same frozen String for a given Module or Class. * Avoids extra allocations whenever calling Module#name. * See [Feature #16150] Notes: Merged: https://github.com/ruby/ruby/pull/2487
2019-09-26[EXPERIMENTAL] Make Symbol#to_s return a frozen StringBenoit Daloze
* Always the same frozen String for a given Symbol. * Avoids extra allocations whenever calling Symbol#to_s. * See [Feature #16150] Notes: Merged: https://github.com/ruby/ruby/pull/2437
2019-09-20Fix documentation for ENV.each to return ENVJeremy Evans
Also have spec check that it returns ENV. Mostly from burdettelamar@yahoo.com (Burdette Lamar). Fixes [Bug #16164]
2019-09-15Refine Timezone fixtureNobuyoshi Nakada
2019-09-09Make test-all and test-spec runnable on AndroidYusuke Endoh
Calling some syscall functions such as Dir.chroot causes SIGSYS instead of EPERM on Android. This change skips all tests that stops the test-suite run.
2019-09-08Improve Proc#to_s specsBenoit Daloze
2019-09-07armv7l and armv7l are the same platform, generalize to armv7Benoit Daloze
[Bug #16007]
2019-09-05Add `File.absolute_path?` (#2198)David Rodríguez
In order to check whether a path is absolute or not in a portable way. [Feature #15868]
2019-09-03Remove bad expectation in specJeremy Evans
This spec should not be checking where methods are defined, only that the method works as expected (returns a Lazy instance). Notes: Merged: https://github.com/ruby/ruby/pull/2421
2019-09-02Prohibit nul-separated glob pattern [Feature #14643] (#2419)Nobuyoshi Nakada
Notes: Merged-By: nobu <nobu@ruby-lang.org>
2019-08-30spec/ruby/core/unboundmethod/bind_call_spec.rb: Add ruby_version_is guardYusuke Endoh
2019-08-30spec/ruby/core/unboundmethod/bind_call_spec.rb: AddedYusuke Endoh
For UnboundMethod#bind_call [Feature #15955] introduced in 002e592e0d67bb0271d16314a32380ad947c9ae9.
2019-08-17Move fixture path to last pathHiroshi SHIBATA
2019-08-14change Proc#to_s format ('@...' -> ' ...') (#2362)Koichi Sasada
Now Proc#to_s returns "#<Proc:0x00000237a0f5f170@t.rb:1>". However, it is convenient to select a file name by (double-)clicking on some terminals by separating ' ' instead of '@' like "#<Proc:0x00000237a0f5f170 t.rb:1>" [Feature #16101]
2019-08-09Fix typo: duplicated the [skip-ci]ohbarye
2019-08-03Suppress warnings against locations in evalNobuyoshi Nakada
2019-07-31Split in two spec examplesBenoit Daloze
2019-07-31Attempt to fix Hash#rehash specBenoit Daloze
2019-07-31delete a check on bad assumption.Koichi Sasada
If object was modified, but there is a case that hash values (#hash) are same between before modified and after modified objects.
2019-07-27Update to ruby/spec@0526d8fBenoit Daloze
2019-07-27Update to ruby/spec@875a09eBenoit Daloze
2019-07-27Initialize DST flagNobuyoshi Nakada
* time.c (zone_timelocal): initialize DST flag by asking the timezone object. [Bug #15988]
2019-07-16Removed twisted testsNobuyoshi Nakada
Why does only Process.daemon have these tests?
2019-07-11File::Stat uses Time#inspectNobuyoshi Nakada
2019-07-04Revert self-referencing finalizer warning [Feature #15974]Nobuyoshi Nakada
It has caused CI failures. * d0cd0866d82a58933e5dccd073c753c0c2ad4eb5 Disable GC during rb_objspace_reachable_object_p * 89cef1c56b3a0f9c5e6ccc22a5044477a4fd16c1 Version guard for [Feature #15974] * 796eeb6339952d92ae1b353d450c7883e589852d. Fix up [Feature #15974] * 928260c2a613bbdd4402c300e0bf86ae7562e52a. Warn in verbose mode on defining a finalizer that captures the object
2019-07-03Version guard for [Feature #15974]Nobuyoshi Nakada
2019-07-03Warn in verbose mode on defining a finalizer that captures the objectChris Seaton
[Feature #15974] Closes: https://github.com/ruby/ruby/pull/2264
2019-07-01Prefer master rather than trunk in README [ci skip]Takashi Kokubun
2019-06-27Update to ruby/spec@94d98ffBenoit Daloze
2019-06-27Update to ruby/spec@8d74d49Benoit Daloze
2019-06-21Alias ENV.merge! as ENV.updateKenichi Kamiya
[Feature #15947] Closes: https://github.com/ruby/ruby/pull/2246