aboutsummaryrefslogtreecommitdiffstats
path: root/test/irb/test_cmd.rb
Commit message (Collapse)AuthorAgeFilesLines
* irb: Removed unused variablesv3_0_0_rc1Nobuyoshi Nakada2020-12-201-2/+0
|
* irb: Define extension command only on the given objectNobuyoshi Nakada2020-12-201-1/+3
| | | | Not to interfer in class variables.
* Set non-verbose mode as well as tty modeNobuyoshi Nakada2020-12-201-0/+4
|
* Set :DEFAULT to PROMPT_MODE for CIaycabta2020-12-201-20/+8
|
* Suppress errors related to using variables that are not directly related to ↵aycabta2020-12-201-4/+20
| | | | testing
* [ruby/irb] Add measure commandaycabta2020-12-201-0/+144
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | You can use "measure" command to check performance in IRB like below: irb(main):001:0> 3 => 3 irb(main):002:0> measure TIME is added. => nil irb(main):003:0> 3 processing time: 0.000058s => 3 irb(main):004:0> measure :off => nil irb(main):005:0> 3 => 3 You can set "measure :on" by "IRB.conf[:MEASURE] = true" in .irbrc, and, also, set custom performance check method: IRB.conf[:MEASURE_PROC][:CUSTOM] = proc { |context, code, line_no, &block| time = Time.now result = block.() now = Time.now puts 'custom processing time: %fs' % (Time.now - time) if IRB.conf[:MEASURE] result } https://github.com/ruby/irb/commit/3899eaf2e2
* Fix typosKazuhiro NISHIYAMA2020-05-091-4/+4
|
* Restore the external and internal encodings of STDIN, STDOUT, and STDERRYusuke Endoh2020-05-081-0/+4
| | | | IRB::ReadlineInputMethod#initialize changes them via IRB.set_encoding.
* test/irb/test_cmd.rb: clear IRB.@CONF on setupYusuke Endoh2020-05-081-0/+1
| | | | | | | | | | | | | | | | | It caches a path to .irbrc file, which has caused random failure: ``` 1) Failure: TestIRB::ExtendCommand#test_irb_info_multiline [/home/mame/work/ruby/test/irb/test_cmd.rb:49]: Expected / Ruby\sversion: .+\n IRB\sversion:\sirb .+\n InputMethod:\sReidlineInputMethod\swith\sReline .+ and .+\n \.irbrc\spath: .+ /x to match "Ruby version: 2.8.0\n" + "IRB version: irb 1.2.3 (2020-02-15)\n" + "InputMethod: ReidlineInputMethod with Reline 0.1.4 and /tmp/test_reline_config_155659/.inputrc\n". ```
* [ruby/irb] Restore the default encodingsNobuyoshi Nakada2020-04-301-0/+4
| | | | IRB::ReadlineInputMethod#initialize sets via IRB.set_encoding.
* [ruby/irb] Suppress messages switching inspect modeNobuyoshi Nakada2020-04-301-0/+4
|
* [ruby/irb] Relaxed regexp for readlineNobuyoshi Nakada2020-04-301-1/+1
| | | | | Readline::VERSION may not be a single word, e.g EditLine wrapper when linked with editline.
* [ruby/irb] Check existence of rc files in irb_info commandaycabta2020-04-291-0/+50
| | | | https://github.com/ruby/irb/commit/cdbb9dfc9f
* [ruby/irb] Add irb_info commandaycabta2020-04-291-0/+64
https://github.com/ruby/irb/commit/a6fe58e916