diff options
| author | Yukihiro "Matz" Matsumoto <[email protected]> | 2019-07-22 21:40:02 +0900 |
|---|---|---|
| committer | GitHub <[email protected]> | 2019-07-22 21:40:02 +0900 |
| commit | 5166e316efc9bd211b3d950d3586a45b22a5f9d5 (patch) | |
| tree | ea96b0f65909b42113851ded0647bc4586b22a8a /mrbgems/mruby-string-ext/test | |
| parent | d2dd2d0e4874ac2522f12b1599842e6cc666088d (diff) | |
| parent | c980fe279266448cf5ac8faa646d57d0f8561b10 (diff) | |
| download | mruby-5166e316efc9bd211b3d950d3586a45b22a5f9d5.tar.gz mruby-5166e316efc9bd211b3d950d3586a45b22a5f9d5.zip | |
Merge pull request #4591 from shuujii/integrate-Integral-chr-Fixnum-chr-to-mruby-string-ext
Integrate `Integral#chr` (`Fixnum#chr`) to `mruby-string-ext`
Diffstat (limited to 'mrbgems/mruby-string-ext/test')
| -rw-r--r-- | mrbgems/mruby-string-ext/test/fixnum.rb | 3 | ||||
| -rw-r--r-- | mrbgems/mruby-string-ext/test/numeric.rb | 5 |
2 files changed, 5 insertions, 3 deletions
diff --git a/mrbgems/mruby-string-ext/test/fixnum.rb b/mrbgems/mruby-string-ext/test/fixnum.rb deleted file mode 100644 index 9036b1a06..000000000 --- a/mrbgems/mruby-string-ext/test/fixnum.rb +++ /dev/null @@ -1,3 +0,0 @@ -assert('Fixnum#chr') do - assert_equal "a", 97.chr -end diff --git a/mrbgems/mruby-string-ext/test/numeric.rb b/mrbgems/mruby-string-ext/test/numeric.rb new file mode 100644 index 000000000..cae562fc1 --- /dev/null +++ b/mrbgems/mruby-string-ext/test/numeric.rb @@ -0,0 +1,5 @@ +assert('Integer#chr') do + assert_equal("A", 65.chr) + assert_equal("B", 0x42.chr) + assert_raise(RangeError) { -1.chr } +end |
