Граф коммитов

14747 Коммитов

Автор SHA1 Сообщение Дата
Sutou Kouhei 303ab5da8b
[ruby/fiddle] test: add missing receiver
https://github.com/ruby/fiddle/commit/1da3b4af16
2021-07-13 19:37:45 +09:00
Sutou Kouhei d1eeb9fec9
[ruby/fiddle] windows: use GetLastError() for win32_last_error
Ruby: [Bug #11579]

Patch by cremno phobia. Thanks!!!

https://github.com/ruby/fiddle/commit/760a8f9b14
2021-07-13 19:37:45 +09:00
Yusuke Endoh 5fd5d71a4b [ruby/error_highlight] Support a file that has no final newline
https://github.com/ruby/error_highlight/commit/9d671284cb
2021-07-13 16:54:17 +09:00
Yusuke Endoh 23c8bc367c [ruby/error_highlight] Support hard tabs
Now, the highlight line is created by replacing non-tab characters with
spaces, and keeping all hard tabs as-is. This means the highlight line
has the completely same indentation as the code snippet line.

Fixes #7

https://github.com/ruby/error_highlight/commit/38f20fa542
2021-07-13 16:51:02 +09:00
Yusuke Endoh 84fea8ee39 [ruby/error_highlight] Update a test for multibyte characters
https://github.com/ruby/error_highlight/commit/2fc70d7f8e
2021-07-12 16:48:52 +09:00
Jeremy Evans 8065670cfb [ruby/date] Fix comparison with Float::INFINITY
Fixes [Bug #17945]

https://github.com/ruby/date/commit/953d907238
2021-07-11 20:28:21 +09:00
aycabta 947d0198e0 [ruby/irb] Show LANG and LC_ALL env by irb_info
Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org>

https://github.com/ruby/irb/commit/b431742430
2021-07-11 06:12:07 +09:00
Nobuyoshi Nakada 491ab2820a
Remove half-defined Reline on LoadError
When fiddle is not avaiable, reline/terminfo depending on it also
fails.
2021-07-10 21:02:50 +09:00
Nobuyoshi Nakada d172f8ac09
Skip fiddle tests if fiddle is not avaiable 2021-07-10 19:14:40 +09:00
Nobuyoshi Nakada 524513be39
mkmf.rb: try linking at try_var
To check for variables accessible but not declared.
2021-07-08 18:18:35 +09:00
Nobuyoshi Nakada 7a2383b5c1
Split test of Hash.[] and add assertion for default value/proc
For a73f13c907.
2021-07-08 16:47:30 +09:00
Martin Dürst 3b36e34b90 Adapt test_emoji_breaks.rb to Unicode 13.0.0/Emoji 13.0
- Add UNICODE_VERSION,... to deal with new location of some
  of the emoji-related data files.
- Introduce class BreakFile to handle various file properties.
- Adapt main code to use BreakFile.
2021-07-08 14:45:03 +09:00
Hiroshi SHIBATA c082c6eb7c Sync RubyGems and Bundler with upstream 2021-07-07 15:31:52 +09:00
David Rodríguez 6e2240a2f9 Sync latest bundler & rubygems development version 2021-07-07 13:30:20 +09:00
Nobuyoshi Nakada 3dacc14fd3 [ruby/rdoc] Fix links without paths
https://github.com/ruby/rdoc/commit/424bd5db4d
2021-07-05 11:34:37 +09:00
Nobuyoshi Nakada f88a9097a4 [ruby/rdoc] Fix for explicit http link
https://github.com/ruby/rdoc/commit/caf234665c
2021-07-05 11:34:35 +09:00
Nobuyoshi Nakada 7c8aa0a5d2 [ruby/rdoc] Allow a label in a link to another document text
https://github.com/ruby/rdoc/commit/85bb2d33bb
2021-07-05 11:34:33 +09:00
Nobuyoshi Nakada 46ab28d6c9 [ruby/rdoc] Fix assertions which look very likely unintended
https://github.com/ruby/rdoc/commit/dc7c890a3d
2021-07-05 11:34:31 +09:00
aycabta caa123b50e [ruby/rdoc] Support ActiveSupport::Concern.included
ref. 168ddaa08a/activerecord/lib/active_record/core.rb (L9-L20)

https://github.com/ruby/rdoc/commit/a2d651dade

Co-authored-by: Fumiaki MATSUSHIMA <mtsmfm@gmail.com>
2021-07-05 11:34:29 +09:00
Nobuyoshi Nakada 2f3edf28f3 [ruby/rdoc] Prefer omit to pend
These conditions are not temporary, rather platform dependent.

https://github.com/ruby/rdoc/pull/815#discussion_r654660411

https://github.com/ruby/rdoc/commit/92545fa250
2021-07-05 11:34:27 +09:00
Ulysse Buonomo ec9a9af375 [ruby/rdoc] Fix chained inclusion ancestors_of
Fixes #814

Signed-off-by: Ulysse Buonomo <buonomo.ulysse@gmail.com>

https://github.com/ruby/rdoc/commit/b45f747216
2021-07-05 11:34:25 +09:00
Nobuyoshi Nakada 0a32cefabd
Add domain check macros 2021-07-04 22:15:59 +09:00
Nobuyoshi Nakada 2488589b2f
Removed extra double quotes from domain error messages 2021-07-04 15:28:25 +09:00
Nobuyoshi Nakada 2d3572a154
Separate toolchain dependent test 2021-07-03 22:11:24 +09:00
Nobuyoshi Nakada 8ebb5e23eb Keep GC disabled until VM bootstrap has done [Bug #17583] 2021-07-01 18:49:17 -07:00
Martin Dürst f6539202c5 - add regression tests for U+6E7F (湿) in ISO-2022-JP
In ISO-2022-JP, the bytes use to code are the same as those for "<>".
  This adds regression tests to make sure that these bytes, when representing
  湿, are NOT escaped with encode("ISO-2022-JP, xml: :text) or similar.
  These are additional regression tests for #12052.
2021-07-01 17:33:43 +09:00
Samuel Williams 42130a64f0
Replace copy coroutine with pthread implementation. 2021-07-01 11:23:03 +12:00
Masataka Pocke Kuwabara e8c2b03ee1 [ruby/irb] Fix error on `ls object_cant_define_singleton`
such as `ls 42`, `ls :sym` and so on

https://github.com/ruby/irb/commit/b1d436a853
2021-06-30 20:55:18 +09:00
Yusuke Endoh b270b5df2c Prevent "warning: ambiguity between regexp and two divisions" 2021-06-30 13:41:18 +09:00
Yusuke Endoh f428ced69c [ruby/error_highlight] Experimentally support a custom formatter
https://github.com/ruby/error_highlight/commit/f40a1de20e
2021-06-30 12:49:18 +09:00
Alan Wu 3dd3ea092a Use Module#ancestors order in recursive constant lookup
Before this commit, const_get with inherit=true and constant lookup
expressions searched the ancestors of the starting point in an order
different from `starting_point.ancestors`.

Items in the ancestry list introduced through prepend were searched
after searching the module they were prepended into. This oddity allowed
for situations where constant lookups gave different results even though
`starting_point.ancestors` is the same.

Do the lookup in the same order as `starting_point.ancestors` by
skipping classes and modules that have an origin iclass. The origin
iclass is in the super chain after the prepended modules.

Note that just like before this commit, the starting point of the
constant lookup is always the first item that we search, regardless of
the presence of any prepended modules.

[Bug #17887]
2021-06-30 10:49:27 +09:00
Yusuke Endoh 9438c99590 Rename error_squiggle to error_highlight 2021-06-29 23:45:49 +09:00
Yusuke Endoh e946049665 [WIP] add error_squiggle gem
```
$ ./local/bin/ruby -e '1.time {}'
-e:1:in `<main>': undefined method `time' for 1:Integer (NoMethodError)

1.time {}
 ^^^^^
Did you mean?  times
```

https://bugs.ruby-lang.org/issues/17930
2021-06-29 23:45:49 +09:00
Samuel Williams 5e75280c8e Add basic test for updated IO wait functions. 2021-06-29 23:54:41 +12:00
Yusuke Endoh 39f99b8176 Use assert_not_match "Did you mean?" for UncorrectableNameCheckTest
... instead of exact matching. I'm now creating a built-in gem that
modifies Exception's error message, so the expectation value is changed.

IMO, it is good to check that did_you_mean suggestion is NOT added in
the uncorrectable case.

https://github.com/ruby/did_you_mean/commit/ebe88ec4d2
2021-06-29 15:49:51 +09:00
Nobuyoshi Nakada 9eae8cdefb
Prefer qualified names under Thread 2021-06-29 11:41:10 +09:00
Nobuyoshi Nakada 13939d61b4
Check if closed after each yield [Bug #17661] 2021-06-27 11:18:41 +09:00
Jeremy Evans e86c1f6fc5
Work around issue transcoding issue with non-ASCII compatible encodings and xml escaping
When using a non-ASCII compatible source and destination encoding
and xml escaping (the :xml option to String#encode), the resulting
string was broken, as it used the correct non-ASCII compatible
encoding, but contained data that was ASCII-compatible instead of
compatible with the string's encoding.

Work around this issue by detecting the case where both the
source and destination encoding are non-ASCII compatible, and
transcoding the source string from the non-ASCII compatible
encoding to UTF-8. The xml escaping code will correctly handle
the UTF-8 source string and the return the correctly encoded
and escaped value.

Fixes [Bug #12052]

Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org>
2021-06-26 12:32:39 -07:00
Nobuyoshi Nakada 391abc543c
Scan the coderange in the given encoding 2021-06-26 16:05:15 +09:00
aycabta 5ffb313ccc Revert "Revert "[ruby/reline] Fix failed test""
I'm so sorry, the previous revert was just a mistake.

This reverts commit 9103c3ba8b.
2021-06-25 18:56:46 +09:00
aycabta 9103c3ba8b Revert "[ruby/reline] Fix failed test"
This reverts commit 491591c7cee842601118efc2698e0e41283827b3.
2021-06-25 17:42:45 +09:00
ima1zumi d340b091a8 [ruby/reline] Fix failed test
For ruby/ruby repository's AppVeyor CI (Windows environment), `Reline::IOGate.encoding` will be changed from `UTF-8` to `Windows-31J` after the test is run.
So, when `test/reline/test_key_actor_emacs.rb` is loaded, `Reline::IOGate.encoding == Encoding::UTF_8` will be `true`,
but at the time of test execution, `Reline::IOGate.encoding` is `Windows-31J`.
For this reason, I changed the test method to check `Reline::IOGate.encoding` in the test method.

https://github.com/ruby/reline/commit/10e1ce3320
2021-06-25 17:42:45 +09:00
Jean Boussier 71344a1d63 [ruby/racc] Stop compressing integer lists
It is unclear why this was implemented, I assume
it was for performance back in 2006.

However today, this compression defeats bytecode caching
entirely and end up being counter productive.

https://github.com/ruby/racc/commit/ae3703c1d0
2021-06-25 17:23:06 +09:00
Jeremy Evans be230615d0 Remove shift of ep when computing Proc#hash
The shift was causing far fewer unique values of hash than expected.

Fix pointed out by xtkoba (Tee KOBAYASHI)

Fixes [Bug #17951]
2021-06-24 12:25:33 -07:00
Jeremy Evans a2592702ae Actually ignore FNM_CASEFOLD flag in Dir.glob
This was already documented as being ignored, but it wasn't being
ignored, causing an issue in a particular case where a UTF-8
pattern was provided and a filename was tested that wasn't valid
UTF-8.

Fixes [Bug #14456]
2021-06-24 12:22:09 -07:00
eileencodes 31f4d26273 Check type of instruction - can be INSN or ADJUST
If the type is ADJUST we don't want to treat it like an INSN so we have
to check the type before reading from `insn_info.events`.

[Bug #18001] [ruby-core:104371]

Co-authored-by: Aaron Patterson <tenderlove@ruby-lang.org>
2021-06-23 11:34:37 -07:00
aycabta 557b4eb4aa Add detailed message to assert_external_string_equal 2021-06-23 21:00:48 +09:00
Nobuyoshi Nakada 298d65b1e4
Discard RDOCOPT environment variable to make tests stable 2021-06-23 18:57:39 +09:00
Nobuyoshi Nakada 09e7a0c4a4
Dispose the global rubygems configuration wholely 2021-06-23 18:56:10 +09:00
Nobuyoshi Nakada ddb8739634
Clear rdoc options in the global rubygems configuration 2021-06-23 18:46:53 +09:00
Nobuyoshi Nakada 69ce9e4187
Clear default configurations
Remove environment variables which can affect the default
configurations.
2021-06-23 15:14:21 +09:00
Nobuyoshi Nakada 950c7a12ef
Make temporary directory under the regular location 2021-06-23 14:17:43 +09:00
Nobuyoshi Nakada 923b365224
Close UserInteraction for tests to fix leaked file descriptors 2021-06-23 12:52:32 +09:00
Hiroshi SHIBATA 6aaa1c4d09 [ruby/rdoc] Use pend instead of skip
https://github.com/ruby/rdoc/commit/8460a36d84
2021-06-23 11:05:18 +09:00
Hiroshi SHIBATA f2e39e5fed [ruby/rdoc] Update test/rdoc/test_rdoc_rubygems_hook.rb
https://github.com/ruby/rdoc/commit/fb264c4cc4

Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org>
2021-06-23 11:05:14 +09:00
Hiroshi SHIBATA c483aa8394 [ruby/rdoc] Rwrite test-case for rubygems_hook without Gem::TestCase
https://github.com/ruby/rdoc/commit/f8d1087ce5
2021-06-23 11:05:11 +09:00
Nobuyoshi Nakada 3b615f4353
Strip trailing spaces 2021-06-23 10:08:51 +09:00
Keiko Kaneko de779f4a62 [ruby/irb] Sort ls result ordered by anscestry
https://github.com/ruby/irb/commit/fdd5c0a71e
2021-06-22 22:32:42 +09:00
Samuel Williams fcc6fd23ec Rework `sysread` to use blocking `read_internal_locktmp`. 2021-06-22 22:48:57 +12:00
Yusuke Endoh ff609eee98 Avoid a duplicated method definition of Object#stub
http://rubyci.s3.amazonaws.com/ubuntu/ruby-master/log/20210622T063005Z.log.html.gz
```
/home/chkbuild/chkbuild/tmp/build/20210622T063005Z/ruby/test/rubygems/helper.rb:1565: warning: method redefined; discarding old stub
/home/chkbuild/chkbuild/tmp/build/20210622T063005Z/ruby/test/resolv/test_dns.rb:8: warning: previous definition of stub was here
```
2021-06-22 16:36:36 +09:00
aycabta 8509532c78 Fix finish_using_lib_reline 2021-06-21 23:13:04 +09:00
aycabta 06d52249de Call super method by teardown of tests of Reline as Readline 2021-06-21 22:29:04 +09:00
aycabta 215fd1bf2c Call Reline-specific method in helper file 2021-06-21 22:26:11 +09:00
aycabta 046fd3ac8c Rescue conversion error of inputrc 2021-06-21 22:12:14 +09:00
aycabta 574c8ee9f1 Call Reline.test_reset in teardown of tests for readline definitely 2021-06-21 22:12:14 +09:00
aycabta e11800e114 Use test encoding for TestRelineAsReadline and TestRelineAsReadlineHistory 2021-06-21 22:12:14 +09:00
aycabta 1192393b3e Stop using global constant, RELINE_TEST_ENCODING 2021-06-21 22:12:14 +09:00
aycabta af19f9a6e9 Call Reline.test_reset in teardown definitely 2021-06-21 22:12:14 +09:00
aycabta 9498ea9385 Revert "Use Encoding.default_external for tests of Readline::HISTORY"
This reverts commit 089a26b0a6.
2021-06-21 22:12:14 +09:00
aycabta 089a26b0a6 Use Encoding.default_external for tests of Readline::HISTORY 2021-06-21 19:31:14 +09:00
aycabta cf6f686d29 [ruby/reline] Remove an obsolete commented-out test
https://github.com/ruby/reline/commit/5354d02e03
2021-06-21 17:58:49 +09:00
aycabta cf186bfe14 [ruby/reline] Add yamatanooroti test about set and exchange mark
https://github.com/ruby/reline/commit/2e6fdca5c6
2021-06-21 17:58:49 +09:00
aycabta 882c0d5015 [ruby/reline] Reset config for random test
https://github.com/ruby/reline/commit/c39615e1dd
2021-06-21 17:58:49 +09:00
aycabta 1b543dc226 [ruby/reline] Handle Errno::ENOTTY correctly
https://github.com/ruby/reline/commit/8daa392ba6
2021-06-21 17:58:48 +09:00
aycabta 754bfc66f8 [ruby/reline] Add a test for pasting Cyrillic chars into command prompt on cp 850
This closes https://github.com/ruby/reline/issues/103.

https://github.com/ruby/reline/commit/213e0523d5
2021-06-21 17:58:48 +09:00
aycabta b0cc46b484 [ruby/reline] The config file must accept any character encoding
In Japan, so many programmers used EUC-JP to write text files that contain
Japanese. Many .inputrc files which contain EUC-JP are still being copied and
used. This commit supports the whole encoding of what user set including UTF-8.

ref. https://github.com/ruby/reline/pull/280

https://github.com/ruby/reline/commit/0b45022e16
2021-06-21 17:58:48 +09:00
aycabta c59bbd86a6 [ruby/reline] Use ReadConsoleInputW() instead of getwch()
This needs https://github.com/aycabta/yamatanooroti/pull/19, which is released
by yamatanooroti gem 0.0.7, to test with yamatanooroti.

https://github.com/ruby/reline/commit/06c1f45da1
2021-06-21 17:58:48 +09:00
Mark Delk a049dfd10a [ruby/reline] ensure reline's encoding is used when reading inputrc character values
This change ensures we use `Reline::IOGate`'s `encoding` when converting
characters from their integer values.

This fixes an issue that may occur if you have UTF characters in your
`.inputrc`, but your default encoding isn't set.

For example:

```
> 127864.ord.chr
RangeError: 127864 out of char range
from (pry):1:in `chr'
> Reline::IOGate.encoding
=> #<Encoding:UTF-8>
> 127864.ord.chr(Reline::IOGate.encoding)
=> "🍸"
```

https://github.com/ruby/reline/commit/cf372fc0fc
2021-06-21 17:58:48 +09:00
Yusuke Endoh acae5f363d ast.rb: RubyVM::AST.parse and .of accepts `save_script_lines: true`
This option makes the parser keep the original source as an array of
the original code lines. This feature exploits the mechanism of
`SCRIPT_LINES__` but records only the specified code that is passed to
RubyVM::AST.of or .parse, instead of recording all parsed program texts.
2021-06-18 02:34:27 +09:00
Nobuyoshi Nakada 95ef545997 [rubygems/rubygems] Close then unlink tempfiles on Windows
In ruby/ruby test actions, number of "leaked tempfile" messages
are shown on Windows.

As Windows disallows removing open files, `Tempfile#unlink` fails
silently before `#close`.
Close then unlink by `#close!` instead.

https://github.com/rubygems/rubygems/commit/fe0b88ac30
2021-06-17 12:28:15 +09:00
Nobuyoshi Nakada d09f097eec
Time#getlocal tests for [Feature #17544] 2021-06-15 21:42:55 +09:00
Eileen M. Uchitelle 2088a45798
[Bug #17880] Set leaf false on opt_setinlinecache (#4565)
This change fixes the bug described in https://bugs.ruby-lang.org/issues/17880.

Checking `ractor_shareable_p` will cause the method to call back into
Ruby. Anything calling this method can't be a leaf instruction,
otherwise it could crash. By adding `attr bool leaf = false` we no
longer crash because it marks the function as not a leaf.

Here's a simplified reproduction script:

```ruby
require "set"

class Id
  attr_reader :db_id
  def initialize(db_id)
    @db_id = db_id
  end

  def ==(other)
    other.class == self.class && other.db_id == db_id
  end
  alias_method :eql?, :==

  def hash
    10
  end

  def <=>(other)
    db_id <=> other.db_id if other.is_a?(self.class)
  end
end

class Namespace
  IDS = Set[
    Id.new(1).freeze,
    Id.new(2).freeze,
    Id.new(3).freeze,
    Id.new(4).freeze,
  ].freeze

  class << self
    def test?(id)
      IDS.include?(id)
    end
  end
end

p Namespace.test?(Id.new(1))
p Namespace.test?(Id.new(5))
```

Co-authored-by: Aaron Patterson <tenderlove@ruby-lang.org>

Co-authored-by: Aaron Patterson <tenderlove@ruby-lang.org>
2021-06-14 17:34:57 -07:00
Marc-Andre Lafortune a09ddfc420 [lib/ostruct] Fix YAML test 2021-06-14 12:28:53 -04:00
Marc-Andre Lafortune 52369fc545 [lib/ostruct] Allow overriding of `block_given?` 2021-06-14 12:28:53 -04:00
Nobuyoshi Nakada edbe0e224c
Suppress exception report in inner thread 2021-06-15 00:03:05 +09:00
Nobuyoshi Nakada 57eaa07ba6
Close leaked file descriptors 2021-06-15 00:02:15 +09:00
jfrazx 931ea7cfbe
Add fallback block to `OpenStruct#delete_field` (#1409) 2021-06-14 09:53:20 -04:00
Bruno Sutic 1ab71a5b98 Fix fiber scheduler address resolve solaris tests 2021-06-14 22:09:23 +12:00
Samuel Williams 050a895439
Wake up join list within thread EC context. (#4471)
* Wake up join list within thread EC context.

* Consume items from join list so that they are not re-executed.

If `rb_fiber_scheduler_unblock` raises an exception, it can result in a
segfault if `rb_threadptr_join_list_wakeup` is not within a valid EC. This
change moves `rb_threadptr_join_list_wakeup` into the thread's top level EC
which initially caused an infinite loop because on exception will retry. We
explicitly remove items from the thread's join list to avoid this situation.

* Verify the required scheduler interface.

* Test several scheduler hooks methods with broken `unblock` implementation.
2021-06-14 17:56:53 +12:00
Samuel Williams 2792acc8f2
Add scheduler hook `Addrinfo.getaddrinfo`. (#4375)
Co-authored-by: Bruno Sutic <code@brunosutic.com>
2021-06-14 16:21:08 +12:00
Jeremy Evans 117310bdc0
Make ENV.clone warn and ENV.dup raise
ENV.dup returned a plain Object, since all of ENV's behavior is
defined in ENV's singleton class.  So using dup makes no sense.

ENV.clone works and is used in some gems, but it doesn't do what
the user expects, since modifying ENV.clone also modifies ENV.
Add a deprecation warning pointing the user to use ENV.to_h
instead.

This also undefines some private initialize* methods in ENV,
since they are not needed.

Fixes [Bug #17767]
2021-06-08 10:19:08 -07:00
Yusuke Endoh 8c87efaa8a [ruby/psych] Fix the test that does not work with libyaml-0.1.7
https://github.com/ruby/psych/commit/542cf9754f
2021-06-08 08:12:27 +09:00
Hiroshi SHIBATA bb4a10208c
Do not use YAML module in tests of Psych 2021-06-07 19:24:20 +09:00
Hiroshi SHIBATA d7146dfd7d
Use assert_raise instead of assert_raises 2021-06-07 19:21:41 +09:00
Jean Boussier fd6225c7a9
[ruby/psych] Implement YAML.safe_dump to make safe_load more usable.
In case where Psych is used as a two way serializers,
e.g. to serialize some cache or config, it is preferable
to have the same restrictions on both load and dump.

Otherwise you might dump and persist some objects payloads
that you later won't be able to read.

https://github.com/ruby/psych/commit/441958396f
2021-06-07 19:15:14 +09:00
Nobuyoshi Nakada 9f3888d6a3 Warn more duplicate literal hash keys
Following non-special_const literals:
* T_REGEXP
2021-06-03 15:11:18 +09:00
Nobuyoshi Nakada 37eb5e7439 Warn more duplicate literal hash keys
Following non-special_const literals:
* T_BIGNUM
* T_FLOAT (non-flonum)
* T_RATIONAL
* T_COMPLEX
2021-06-03 15:11:18 +09:00
Nobuyoshi Nakada a023db49bf Assertions for duplicate literal hash key warnings 2021-06-03 15:11:18 +09:00
Yusuke Endoh b957c3dbcb [rubygems/rubygems] Rename test/rubygems/test_{case,utilities}.rb to avoid "test_" prefix
This changes "test/rubygems/test_case.rb" to "test/rubygems/helper.rb",
and "test/rubygems/test_utilities.rb" to "test/rubygems/utilities.rb".

The two files are a helper for tests, not test files. However, a file
starting with "test_" prefix is handled as a test file directly loaded
by test-unit because Rakefile specifies:

```
t.test_files = FileList['test/**/test_*.rb']
```

Directly loading test/rubygems/test_utilities.rb caused "uninitialized
constant Gem::TestCase". This issue was fixed by
59c6820971, but the fix caused a
"circular require" warning because test_utilities.rb and test_case.rb
are now requiring each other.

Anyway, adding "test_" prefix to a test helper file is confusing, so
this changeset reverts the fix and solve the issue by renaming them.

https://github.com/rubygems/rubygems/commit/6460e018df
2021-06-03 12:23:22 +09:00
aycabta 77e1b47729 [ruby/rdoc] Add an alias for test-unit with older versions of RubyGems
https://github.com/ruby/rdoc/commit/b8d68fdd87
2021-06-02 11:35:45 +09:00
Nobuyoshi Nakada 9024c7f1bb
Make `Thread#native_thread_id` not-implemented if unsupported
Raise `NotImplementedError` on unsupported platforms regardless
the argument consistently.
2021-06-01 22:27:13 +09:00
aycabta c9ab8fe2b1 The test for command injection on Unix platforms should be omitted on Windows 2021-05-31 23:34:40 +09:00
Jeremy Evans fd65ef2a5a Attempt to fix floating point test failure
The previous behavior depending on exact float values, it seemed
to work OK on amd64 and i386, but other CI platforms are
experiencing non-deterministic test failures with it. Relax test
slightly to hopefully pass on such platforms.
2021-05-29 14:08:24 -07:00
Jeremy Evans f516379853 Fix Enumerator::ArithmeticSequence handling of float ranges
Depending on the float range, there could be an off-by-one error,
where the last result that should be in the range was missed. Fix
this by checking if the computed value for the expected value
outside the range is still inside the range, and if so, increment
the step size.

Fixes [Bug #16612]
2021-05-29 08:56:15 -07:00
Alan Wu 5ada23ac12 compile.c: Emit send for === calls in when statements
The checkmatch instruction with VM_CHECKMATCH_TYPE_CASE calls
=== without a call cache. Emit a send instruction to make the call
instead. It includes a call cache.

The call cache improves throughput of using when statements to check the
class of a given object. This is useful for say, JSON serialization.

Use of a regular send instead of checkmatch also avoids taking the VM
lock every time, which is good for multi-ractor workloads.

    Calculating -------------------------------------
                             master        post
         vm_case_classes    11.013M     16.172M i/s -      6.000M times in 0.544795s 0.371009s
             vm_case_lit      2.296       2.263 i/s -       1.000 times in 0.435606s 0.441826s
                 vm_case    74.098M     64.338M i/s -      6.000M times in 0.080974s 0.093257s

    Comparison:
                      vm_case_classes
                    post:  16172114.4 i/s
                  master:  11013316.9 i/s - 1.47x  slower

                          vm_case_lit
                  master:         2.3 i/s
                    post:         2.3 i/s - 1.01x  slower

                              vm_case
                  master:  74097858.6 i/s
                    post:  64338333.9 i/s - 1.15x  slower

The vm_case benchmark is a bit slower post patch, possibily due to the
larger instruction sequence. The benchmark dispatches using
opt_case_dispatch so was not running checkmatch and does not make the
=== call post patch.
2021-05-28 12:34:03 -04:00
Hiroshi SHIBATA 12214b7814
Resolve to missing `Gem::TestCase` issue with random order tests 2021-05-28 14:01:58 +09:00
Hiroshi SHIBATA e487ba7dda
[rubygems/rubygems] Use pend instead of skip 2021-05-28 12:33:16 +09:00
David Rodríguez a634ef5376 [rubygems/rubygems] Fix "instance variable not initialized" warning
This variable had a typo (it's `@gemhome`), but the test is still
passing, so I assume it's not needed.

https://github.com/rubygems/rubygems/commit/3b88642bdb
2021-05-28 11:53:57 +09:00
David Rodríguez 1f505000e6 [rubygems/rubygems] Test installing a non deprecated file
https://github.com/rubygems/rubygems/commit/a678959eda
2021-05-28 11:53:45 +09:00
David Rodríguez 9382bda78b [rubygems/rubygems] Remove no longer needed `RUBYGEMS_TEST_PATH` env variable
https://github.com/rubygems/rubygems/commit/0efb894c3b
2021-05-28 11:53:33 +09:00
David Rodríguez 4fb3dd2c42 [rubygems/rubygems] Remove no longer relevant commentsº
https://github.com/rubygems/rubygems/commit/8dfe1e30b5
2021-05-28 11:53:21 +09:00
David Rodríguez f7732ae2eb [rubygems/rubygems] Require the new files in `test/` relatively
https://github.com/rubygems/rubygems/commit/c77868a555
2021-05-28 11:53:09 +09:00
David Rodríguez 59c6820971 [rubygems/rubygems] Copy files specific to testing rubygems to `test`
https://github.com/rubygems/rubygems/commit/aa390a3500
2021-05-28 11:52:57 +09:00
Hiroshi SHIBATA f7d661e783
[rubygems/rubygems] Try fix ruby-core CI
* Port
8e91b969df
from ruby-core, and make it compatible with psych 3 & 4.
2021-05-28 11:52:32 +09:00
Jeremy Evans fd8991f797 Fix lazy enumerator with index size
Fixes [Bug #17889]
2021-05-27 14:17:32 -07:00
Hiroshi SHIBATA 350bc29107 Guard for the ftp protocol feature of OpenURI 2021-05-27 14:42:11 +09:00
Hiroshi SHIBATA b8dcad8d32 Defer to require prime for OpenSSL::TestBN 2021-05-27 14:42:11 +09:00
Hiroshi SHIBATA be2e2b4805 Promote net-smtp to the bundled gems 2021-05-27 14:42:11 +09:00
Hiroshi SHIBATA aa9726f7b9 Promote net-pop to the bundled gems 2021-05-27 14:42:11 +09:00
Hiroshi SHIBATA d5bc6b2337 Promote net-imap to the bundled gems 2021-05-27 14:42:11 +09:00
Hiroshi SHIBATA e49c998d1e Promote net-ftp to the bundled gems 2021-05-27 14:42:11 +09:00
Hiroshi SHIBATA 454a36794f Promote matrix to the bundled gems 2021-05-27 14:42:11 +09:00
Hiroshi SHIBATA c9178c1127 Promote prime to the bundled gems 2021-05-27 14:42:11 +09:00
Yusuke Endoh 055ec5254d Rescue NotImplementedError for a test of Thread#native_thread_id
http://rubyci.s3.amazonaws.com/solaris10-gcc/ruby-master/log/20210526T070003Z.fail.html.gz
```
  1) Error:
TestThread#test_thread_native_thread_id:
NotImplementedError: native_thread_id() function is unimplemented on this machine
    /export/home/users/chkbuild/cb-gcc/tmp/build/20210526T070003Z/ruby/test/ruby/test_thread.rb:1338:in `native_thread_id'
    /export/home/users/chkbuild/cb-gcc/tmp/build/20210526T070003Z/ruby/test/ruby/test_thread.rb:1338:in `test_thread_native_thread_id'
```
2021-05-26 18:02:06 +09:00
Nobuyoshi Nakada 251fafec1b
Suppress debug message 2021-05-26 15:33:25 +09:00
NARUSE, Yui 46655156dc Add Thread#native_thread_id [Feature #17853] 2021-05-26 15:14:11 +09:00
Hiroshi SHIBATA 88e3848fca
RSS library is the bundled gems now 2021-05-26 11:39:01 +09:00
Hiroshi SHIBATA e54bef92d5
Ignore lib/irb/ext/tracer.rb with TestRequireLib because tracer library was removed from ruby repo 2021-05-26 10:04:24 +09:00
Aaron Patterson fc832ffbfa Disable compaction on platforms that can't support it
Manual compaction also requires a read barrier, so we need to disable
even manual compaction on platforms that don't support mprotect.

[Bug #17871]
2021-05-25 17:37:21 -07:00
Hiroshi SHIBATA edcc29dcff Removed gdbm from ruby repo 2021-05-25 20:04:54 +09:00
Hiroshi SHIBATA 55cd3e4ebf Removed dbm from ruby repo 2021-05-25 15:18:31 +09:00
Hiroshi SHIBATA ab3266ea5c Removed tracer from ruby repo 2021-05-25 13:13:52 +09:00
aycabta f57968e329 Set USE_COLORIZE to the default value in a test 2021-05-24 12:13:46 +09:00
jethrodaniel d06d4560a1 [ruby/irb] update test/irb/test_init.rb to avoid useless eval
Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org>

https://github.com/ruby/irb/commit/2dfdc031ec
2021-05-24 11:56:05 +09:00
Mark Delk b8ffb1c46f [ruby/irb] respect NO_COLOR environment variable
When `NO_COLOR` is set to any non-nil value, output is not colorized.

See https://no-color.org/

https://github.com/ruby/irb/commit/401d0916fe
2021-05-24 11:55:58 +09:00
aycabta c264d30261 Use YAML.safe_load to use the permitted_classes option 2021-05-21 21:45:03 +09:00
Nobuyoshi Nakada c4162a4cb8
Refined portability of test for [Bug #17739]
The order of arguments to callback of qsort is not defined.
That means `a` may not be 3 at all.
2021-05-22 14:34:23 +09:00
Jeremy Evans 8b00bfb7c2
Do not allow array modifications after freeze inside sort!
If freezing an array inside sort!, previously the array could be
modified after the freeze.  This checks whether the receiver is
frozen after every yield and potential call to #> or #<,
preventing modifications if the receiver is frozen inside the
block or by the #> or #< call.

Fixes [Bug #17739]
2021-05-21 18:33:56 -07:00
Alan Wu b2fc592c30
Build CDHASH properly when loading iseq from binary
Before this change, CDHASH operands were built as plain hashes when
loaded from binary. Without setting up the hash with the correct
st_table type, the hash can sometimes be an ar_table. When the hash is
an ar_table, lookups can call the `eql?` method on keys of the hash,
which makes the `opt_case_dispatch` instruction not "leaf" as it
implicitly declares.

The following script trips the stack canary for checking the leaf
attribute for `opt_case_dispatch` on VM_CHECK_MODE > 0 (enabled by
default with RUBY_DEBUG).

    rb_vm_iseq = RubyVM::InstructionSequence

    iseq = rb_vm_iseq.compile(<<-EOF)
      case Class.new(String).new("foo")
      when "foo"
        42
      end
    EOF

    puts rb_vm_iseq.load_from_binary(iseq.to_binary).eval

This commit changes the binary loading logic to build CDHASH with the
right st_table type. The dumping logic and the dump format stays the
same
2021-05-21 12:13:55 -04:00
Alan Wu 636d4f7eb9 Avoid setting the visibility of refinement method entries
Since refinement search is always performed, these entries should always
be public. The method entry that the refinement search returns decides
the visibility.

Fixes [Bug #17822]
2021-05-21 12:12:31 -04:00
Nobuyoshi Nakada 50a534a152 ripper: wrap endless method in bodystmt [Bug #17869] 2021-05-21 18:28:24 +09:00
Nobuyoshi Nakada 050bb06e66 ripper: assertions for rescue/ensure in method body 2021-05-21 18:28:24 +09:00
Nobuyoshi Nakada e9974a466a
Get rid of sporadic WSAEACCES on Windows [ruby-dev:42661] 2021-05-21 18:26:07 +09:00
Koichi Sasada 817764bd82 simple rescue+while+break should not use `throw`
609de71f04 fixes the issue by using
`throw` insn if `ensure` is used. However, that patch introduce
additional `throw` even if it is not needed. This patch solves
the issue.

This issue is pointed by @mame.
2021-05-21 18:12:14 +09:00
Nobuyoshi Nakada 59b327aa58
[ruby/rdoc] Drop support for Ruby 2.4
https://github.com/ruby/rdoc/commit/f480b970cc
2021-05-21 15:53:34 +09:00
Nobuyoshi Nakada f18a0b7654
[ruby/rdoc] Follow-up rubygems
Use test-unit assertions instead of minitest.

https://github.com/ruby/rdoc/commit/d6a6209d7f
2021-05-21 15:53:34 +09:00
Nobuyoshi Nakada 10e63f3f56
[ruby/rdoc] Vertical-bar is disallowed in path names on Windows
No risk of remote code execution, when the file cannot be created.

https://github.com/ruby/rdoc/runs/2565343916?check_suite_focus=true#step:5:58
```
Error: test_remove_unparseable_CVE_2021_31799(TestRDocRDoc): Errno::EINVAL: Invalid argument @ utime_failed - | touch evil.txt && echo tags
D:/rubyinstaller-head-x64/lib/ruby/3.1.0/fileutils.rb:1142:in `utime'
D:/rubyinstaller-head-x64/lib/ruby/3.1.0/fileutils.rb:1142:in `block in touch'
D:/rubyinstaller-head-x64/lib/ruby/3.1.0/fileutils.rb:1139:in `each'
D:/rubyinstaller-head-x64/lib/ruby/3.1.0/fileutils.rb:1139:in `touch'
D:/a/rdoc/rdoc/test/rdoc/test_rdoc_rdoc.rb:463:in `block (2 levels) in test_remove_unparseable_CVE_2021_31799'
     460:     temp_dir do
     461:       file_list = ['| touch evil.txt && echo tags']
     462:       file_list.each do |f|
  => 463:         FileUtils.touch f
     464:       end
     465:
     466:       assert_equal file_list, @rdoc.remove_unparseable(file_list)
```

https://github.com/ruby/rdoc/commit/a7df7dc8fa
2021-05-21 15:53:34 +09:00
Nobuyoshi Nakada a298bdf860
[ruby/rdoc] Dir.children is 2.5+
RDoc seems still supporting outdated 2.4.

https://github.com/ruby/rdoc/runs/2565344070?check_suite_focus=true#step:5:64
```
Error: test_remove_unparseable_CVE_2021_31799(TestRDocRDoc): NoMethodError: undefined method `children' for Dir:Class
/home/runner/work/rdoc/rdoc/test/rdoc/test_rdoc_rdoc.rb:467:in `block in test_remove_unparseable_CVE_2021_31799'
     464:       end
     465:
     466:       assert_equal file_list, @rdoc.remove_unparseable(file_list)
  => 467:       assert_equal file_list, Dir.children('.')
     468:     end
     469:   end
     470:
```

https://github.com/ruby/rdoc/commit/5a4a64dc0f
2021-05-21 15:53:34 +09:00
aycabta b1c73f239f [ruby/rdoc] Use File.open to fix the OS Command Injection vulnerability in CVE-2021-31799
https://github.com/ruby/rdoc/commit/a7f5d6ab88
2021-05-21 13:42:24 +09:00
Nobuyoshi Nakada c711093559 Get rid of sporadic WSAEACCES on Windows [ruby-dev:42661] 2021-05-20 21:56:58 +09:00
Yusuke Endoh 5026f9a5d5 compile.c: stop the jump-jump optimization if the second has any event
Fixes [Bug #17868]
2021-05-20 19:13:39 +09:00
Hiroshi SHIBATA adcbae8d49
Removed minitest/mock 2021-05-19 14:24:01 +09:00
Yusuke Endoh ceea1ea8af test/rubygems/test_gem_commands_open_command.rb: prevent a warning
http://rubyci.s3.amazonaws.com/debian9/ruby-master/log/20210518T093002Z.log.html.gz
```
[ 9396/21186] TestGemCommandsOpenCommand#test_execute-e:1: warning: possibly useless use of a literal in void context
 = 0.06 s
```
2021-05-18 19:06:48 +09:00
Yusuke Endoh 837cbea64b test/psych/test_coder.rb: Suppress non-parenthesis warnings
http://rubyci.s3.amazonaws.com/debian9/ruby-master/log/20210518T093002Z.log.html.gz
```
/home/chkbuild/chkbuild/tmp/build/20210518T093002Z/ruby/test/psych/test_coder.rb:277: warning: ambiguity between regexp and two divisions: wrap regexp in parentheses or add a space after `/' operator
```
2021-05-18 19:01:27 +09:00
Nobuyoshi Nakada 34bc8210ed
test/irb/test_raise_no_backtrace_exception.rb: fix test file path
Create a file for test under the temporary directory.
2021-05-18 16:04:37 +09:00
Jeremy Evans 2579593a56 [ruby/fiddle] Do not use a libdir for glibc, it breaks Linux PPC64 (#70)
Fixes [Bug #12666]

https://github.com/ruby/fiddle/commit/a267a40be7
2021-05-18 12:48:40 +09:00
Sutou Kouhei ab5212b3c9 [ruby/fiddle] Add support for "const" in type
GitHub: fix #68

Reported by kojix2. Thanks!!!

https://github.com/ruby/fiddle/commit/d7322c234a
2021-05-18 12:48:40 +09:00
Sutou Kouhei 881b2dc898 [ruby/fiddle] closure: add support for const char *
GitHub: fix GH-62

Reported by Cody Krieger. Thanks!!!

https://github.com/ruby/fiddle/commit/284b820f2d
2021-05-18 12:48:40 +09:00
Sutou Kouhei b2de5999d8 [ruby/fiddle] closure: accept symbol as type
https://github.com/ruby/fiddle/commit/dc2da6633e
2021-05-18 12:48:40 +09:00
Hiroshi SHIBATA e36da7ba18
Revert an accidentally commits at df86a13cc1 2021-05-17 15:28:47 +09:00
Yusuke Endoh 31a757a442 Make the test pass with the old libyaml
I have no idea what result is right, but it fails with libyaml 0.1.7
(bundled with Ubuntu 18.04) anyway.
2021-05-17 14:31:34 +09:00
Yusuke Endoh f367b4ffe7 assert_equal accepts an expected value as the first argument 2021-05-17 14:31:34 +09:00
Yusuke Endoh ffdf0232ef lib/rdoc/rdoc.rb: Allow only RDoc::Options in .rdoc_options
Follow-up of d8fd92f620. Instead of using
unsafe_load blindly, RDoc::Options is only supposed to be allowed.
2021-05-17 12:53:42 +09:00
Hiroshi SHIBATA d8fd92f620
Workaround with fbb4e3f96c in rdoc 2021-05-17 12:04:40 +09:00
Hiroshi SHIBATA 8e91b969df
Workaround with fbb4e3f96c 2021-05-17 12:00:05 +09:00
Yusuke Endoh da5b283963 test/ostruct/test_ostruct.rb: Use YAML.unsafe_load instead of YAML.load
Follow-up of fbb4e3f96c
2021-05-17 11:36:16 +09:00
Aaron Patterson 42b20bdbfe
[ruby/psych] remove deprecated interface
https://github.com/ruby/psych/commit/0767227051
2021-05-17 11:20:46 +09:00
Aaron Patterson c7c2ad5749
[ruby/psych] Introduce `Psych.unsafe_load`
In future versions of Psych, the `load` method will be mostly the same
as the `safe_load` method.  In other words, the `load` method won't
allow arbitrary object deserialization (which can be used to escalate to
an RCE).  People that need to load *trusted* documents can use the
`unsafe_load` method.

This commit introduces the `unsafe_load` method so that people can
incrementally upgrade.  For example, if they try to upgrade to 4.0.0 and
something breaks, they can downgrade, audit callsites, change to
`safe_load` or `unsafe_load` as required, and then upgrade to 4.0.0
smoothly.

https://github.com/ruby/psych/commit/cb50aa8d3f
2021-05-17 11:20:45 +09:00
Hiroshi SHIBATA bcaa6aecea
[ruby/psych] Removed needless platform detection
https://github.com/ruby/psych/commit/57d704fd63
2021-05-17 11:20:45 +09:00
Hiroshi SHIBATA df86a13cc1
[ruby/psych] Import test assertions from ruby/ruby
https://github.com/ruby/psych/commit/01dda86681
2021-05-17 11:20:45 +09:00
Jean Boussier a3ceed50b8
[ruby/psych] Fix symabolize_name with non-string keys
https://github.com/ruby/psych/commit/1c5c29e81f
2021-05-17 11:20:45 +09:00
Jeremy Ebler 830778db95
[ruby/psych] feat: allow scalars and sequences to be styled when dumped
https://github.com/ruby/psych/commit/546154ddb7
2021-05-17 11:20:45 +09:00
Gabriel Nagy 229cb0fcdb
[Win32] long path name support [Bug #12551]
Implement long path support on Windows by applying Microsoft's
recommended application manifest.

To make this work on both Visual C++ and MinGW, include the manifest as
a resource when generating the resource files. This way it will be
embedded into the executables generated by both compilers.

It's important for the manifest resource to have ID 1, otherwise GCC
will embed a default manifest.

Note that in addition to this, the user needs to have [long paths enabled]
either by modifying the registry or by enabling a group policy.

[long paths enabled]: https://docs.microsoft.com/en-us/windows/win32/fileio/maximum-file-path-limitation?tabs=cmd#enable-long-paths-in-windows-10-version-1607-and-later

Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org>
2021-05-17 08:33:08 +09:00
Yusuke Endoh f210d456a8 test/objspace/test_objspace.rb: check stderr before stdout
When `require "objspace/trace"` fails, previously the failure says:
```
  1) Failure:
TestObjSpace#test_objspace_trace [/tmp/ruby/v3/src/trunk-mjit/test/objspace/test_objspace.rb:621]:
<3> expected but was
<0>.
```
but this is hard to debug.
2021-05-14 18:07:58 +09:00
Yusuke Endoh 702961a88b test/ruby/test_refinement.rb: prevent "assigned but unused variable" 2021-05-14 15:44:13 +09:00
Yusuke Endoh cf1e1879f1 ext/objspace/lib/objspace/trace.rb: Added
This file, when require'ed, starts tracing the object allocations, and
redefines `Kernel#p` to show the allocation site.

This commit is experimental; the library name and APIs may change.

[Feature #17762]
2021-05-14 13:40:32 +09:00
Nobuyoshi Nakada 110f242ef9
Also `\U` after control/meta is invalid [Bug #17861]
As well as `\u`, `\U` should be invalid there too.
And highlight including `u`/`U` not only the backslash before it.
2021-05-13 12:54:56 +09:00
Jeremy Evans 9ce29c94d8 Avoid improper optimization of case statements mixed integer/rational/complex
Fixes [Bug #17857]
2021-05-12 19:30:05 -07:00
Jeremy Evans 11ae581a4a Fix handling of control/meta escapes in literal regexps
Ruby uses a recursive algorithm for handling control/meta escapes
in strings (read_escape).  However, the equivalent code for regexps
(tokadd_escape) in did not use a recursive algorithm.  Due to this,
Handling of control/meta escapes in regexp did not have the same
behavior as in strings, leading to behavior such as the following
returning nil:

```ruby
/\c\xFF/ =~ "\c\xFF"
```

Switch the code for handling \c, \C and \M in literal regexps to
use the same code as for strings (read_escape), to keep behavior
consistent between the two.

Fixes [Bug #14367]
2021-05-12 18:55:43 -07:00
Yusuke Endoh 9484f9ebdf [rubygems/rubygems] Use `Time.stub :now` to avoid a random failure
Essentially this reverts 45464bfcbdf9f9cfb440950bc57a27d237627a17.
The commit removed a mock of Time.now, which caused a random failure.

http://rubyci.s3.amazonaws.com/ubuntu1804/ruby-master/log/20210512T123004Z.fail.html.gz
```
  1) Failure:
TestGemPackageTarWriter#test_add_file_signer [/home/chkbuild/chkbuild/tmp/build/20210512T123004Z/ruby/test/rubygems/test_gem_package_tar_writer.rb:117]:
Field mtime of the tar header differs..
<"14046746312\u0000"> expected but was
<"14046746311\x00">.
```

Object#stub is defined at f1af59fe02ef2cc58f13e2742e4cc6cf8c2a1a20, so
now `Time.stub :now` works.

https://github.com/rubygems/rubygems/commit/85f60a9ed0
2021-05-13 09:26:13 +09:00
Yusuke Endoh 31794d2e73 parse.y: Allow "command" syntax in endless method definition
This change allows `def hello = puts "Hello"` without parentheses.

Note that `private def hello = puts "Hello"` does not parse for
technical reason.

[Feature #17398]
2021-05-13 00:14:50 +09:00
git 81513c9dab * remove trailing spaces. [ci skip] 2021-05-12 17:40:52 +09:00
Koichi Sasada 523a6998dd Use another class for the comparison.
`memsize_of(Object.new)` can be changed with past ivar creation
history for Object instances (another Object instance has 4 or
more ivars, next created Object instance has the area for the
ivars). So use antoher class for the comparison.
2021-05-12 17:40:31 +09:00
Hiroshi SHIBATA 81720b947a Use assert_raise instead of assert_raises 2021-05-12 17:24:43 +09:00
Hiroshi SHIBATA cdcfe1082c Revert 924ce2c5ba4d1c1dc781a6a06682204d358421bb
Because test-unit didn't provide the benchmark test. And This test
  is fragile with the several environments.
2021-05-12 17:24:43 +09:00
Hiroshi SHIBATA bef49e6e8d [rubygems/rubygems] Added begin-end block for java platform
Because pend of test-unit raises exception.

https://github.com/rubygems/rubygems/commit/b5e2d0855a
2021-05-12 17:24:43 +09:00
Hiroshi SHIBATA d33888bf96 [rubygems/rubygems] Replace skip to pend
https://github.com/rubygems/rubygems/commit/0b145135c7
2021-05-12 17:24:43 +09:00
Hiroshi SHIBATA 129bc04ab7 [rubygems/rubygems] util/rubocop -a
https://github.com/rubygems/rubygems/commit/a10ff97830
2021-05-12 17:24:43 +09:00
Hiroshi SHIBATA 00f5b4b546 [rubygems/rubygems] Don't use Minitest::Mock
https://github.com/rubygems/rubygems/commit/d3fa893597
2021-05-12 17:24:43 +09:00
Hiroshi SHIBATA 3456335a9c [rubygems/rubygems] Removed minitest/mock from test/rubygems/test_gem_remote_fetcher.rb
https://github.com/rubygems/rubygems/commit/f1af59fe02
2021-05-12 17:24:43 +09:00
Hiroshi SHIBATA ff3f990499 [rubygems/rubygems] Removed minitest/mock from test_gem_package_tar_writer.rb
https://github.com/rubygems/rubygems/commit/45464bfcbd
2021-05-12 17:24:43 +09:00
Hiroshi SHIBATA 7b3b48549b [rubygems/rubygems] capture_output will return empty string, not nil
https://github.com/rubygems/rubygems/commit/3fa93f6144
2021-05-12 17:24:43 +09:00
Hiroshi SHIBATA 9b5e4ce611 [rubygems/rubygems] Fixed variable scope at test_silent_system
https://github.com/rubygems/rubygems/commit/bfcdf79657
2021-05-12 17:24:43 +09:00
Hiroshi SHIBATA cd375e455e [rubygems/rubygems] Rewrite with capture_output
https://github.com/rubygems/rubygems/commit/a091004ded
2021-05-12 17:24:43 +09:00
Hiroshi SHIBATA 5ed9d3f16f [rubygems/rubygems] Use capture_output instead of capture_io
https://github.com/rubygems/rubygems/commit/c46185abe3
2021-05-12 17:24:43 +09:00
Hiroshi SHIBATA c30594bb0c [rubygems/rubygems] Use assert_raise instead of assert_raises
https://github.com/rubygems/rubygems/commit/769e87f011
2021-05-12 17:24:43 +09:00
Hiroshi SHIBATA 2c0072dec5 [rubygems/rubygems] Use dummy assertion for assert_https
https://github.com/rubygems/rubygems/commit/64d843fe17
2021-05-12 17:24:43 +09:00
Hiroshi SHIBATA a1c416460b [rubygems/rubygems] Use capture_output instead of assert_silent
https://github.com/rubygems/rubygems/commit/3225aab7f8
2021-05-12 17:24:43 +09:00
Hiroshi SHIBATA 958f9d425a [rubygems/rubygems] Use capture_output instead of capture_io for test-unit
https://github.com/rubygems/rubygems/commit/ab9c80d4cb
2021-05-12 17:24:43 +09:00
Hiroshi SHIBATA 3948be3503 [rubygems/rubygems] Use assert_path_exist and assert_path_not_exist instead of assert_path_exists and refute_path_exists
https://github.com/rubygems/rubygems/commit/a7c93558c3
2021-05-12 17:24:43 +09:00