Commit graph

9 commits

Author SHA1 Message Date
lukeg
418cf344fb [ruby/irb] Fix 2 minor issues in test suite
* undefine Kernel#irb_original_require in without_rdoc method
* Don't rescue all LoadErrors/NameErrors in test_rendering.rb, just
the one for require 'yamatanooroti'

52b79806ea
2023-03-17 15:19:40 +00:00
Stan Lo
7161bf34e1 [ruby/irb] Require pathname in test helper
(https://github.com/ruby/irb/pull/467)

39c6924c12
2022-12-02 22:00:42 +00:00
Stan Lo
69fd673b1a [ruby/irb] Disable debug cmd tests based on project structure
instead of env
(https://github.com/ruby/irb/pull/466)

It's hard to find an env var that's universally set in all Ruby CI
environments but not in local. Checking gemspec seems to be a better way
as `syntax_suggest` already uses it for a while.

d8f1bca297/spec/spec_helper.rb (L47)
2022-12-02 20:43:59 +00:00
Takashi Kokubun
67034ac7e2 [ruby/irb] Deal with inconsistency with ruby/ruby
41d5012849
2022-11-20 05:34:51 +00:00
Takashi Kokubun
8512b97d27 [ruby/irb] Require missing EnvUtil
9bb1757b02
2022-11-20 05:32:11 +00:00
Hiroshi SHIBATA
36dc99af5a
Added empty class for test methods in TestIRB cases 2022-11-15 20:19:43 +09:00
st0012
1eae15142f [ruby/irb] Remove duplicated TestInputMethod definitions
4b831d02e1
2022-11-15 10:07:32 +00:00
Stan Lo
a923203811 [ruby/irb] Provide a base test class and let tests restore encodings
conveniently
(https://github.com/ruby/irb/pull/429)

* Create a base TestIRB::TestCase class

* Save/restore encodings for tests that initializes InputMethod classes

Because `RelineInputMethod#initializes` calls `set_encoding`, which
changes stdio/out/err and Encoding's default encoding values, we need to
make sure any test that directly or indirectly (e.g. through Context)
initializes `RelineInputMethod` restores encodings.

`ReadlineInputMethod` also changes encodings but currently no tests
cover it.

* Remove unnecessary TestHelper module

Since we now have a base TestCase, without_rdoc can just live there.

c2874ec121
2022-11-03 22:13:11 +00:00
Peter Zhu
73a0223f95 [ruby/irb] Rename test_helper.rb to helper.rb
The name test_helper.rb conflicts with the test_helper.rb in JSON,
causing build failures. This commit renames test_helper.rb to helper.rb.

b6a92bf6b3

Co-Authored-By: Stan Lo <stan001212@gmail.com>
2022-10-26 15:13:44 +00:00
Renamed from test/irb/test_helper.rb (Browse further)