diff options
Diffstat (limited to 'test/reline/helper.rb')
-rw-r--r-- | test/reline/helper.rb | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/test/reline/helper.rb b/test/reline/helper.rb index 0b5b8af310..5593b0a602 100644 --- a/test/reline/helper.rb +++ b/test/reline/helper.rb @@ -7,6 +7,7 @@ module Reline def test_mode remove_const('IOGate') if const_defined?('IOGate') const_set('IOGate', Reline::GeneralIO) + Reline::GeneralIO.reset send(:core).config.instance_variable_set(:@test_mode, true) send(:core).config.reset end @@ -17,6 +18,14 @@ module Reline end end +def start_pasting + Reline::GeneralIO.start_pasting +end + +def finish_pasting + Reline::GeneralIO.finish_pasting +end + RELINE_TEST_ENCODING ||= if ENV['RELINE_TEST_ENCODING'] Encoding.find(ENV['RELINE_TEST_ENCODING']) |