summaryrefslogtreecommitdiffhomepage
path: root/test/t/string.rb
diff options
context:
space:
mode:
authorYukihiro "Matz" Matsumoto <[email protected]>2019-01-03 11:34:35 +0900
committerYukihiro "Matz" Matsumoto <[email protected]>2019-01-03 11:34:35 +0900
commitcca19532c5f71e1bdc0b4947b2fcddd181f27781 (patch)
treec65545fead5be8f7c7a5d4010fc12c4823751d55 /test/t/string.rb
parentf9d89e3fa592706de6a6dee701af3961df914292 (diff)
downloadmruby-cca19532c5f71e1bdc0b4947b2fcddd181f27781.tar.gz
mruby-cca19532c5f71e1bdc0b4947b2fcddd181f27781.zip
Remove `Kernel#class_defined?` which is not available in CRuby; #3829
Diffstat (limited to 'test/t/string.rb')
-rw-r--r--test/t/string.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/test/t/string.rb b/test/t/string.rb
index 3a1eced16..8f008c6a7 100644
--- a/test/t/string.rb
+++ b/test/t/string.rb
@@ -155,7 +155,7 @@ assert('String#[]=') do
d[-10] = 'X'
end
- if class_defined?("Float")
+ if Object.const_defined?(:Float)
e = 'abc'
e[1.1] = 'X'
assert_equal 'aXc', e
@@ -618,7 +618,7 @@ assert('String#to_f', '15.2.10.5.38') do
assert_float(12345.6789, c)
assert_float(0, d)
assert_float(Float::INFINITY, e)
-end if class_defined?("Float")
+end if Object.const_defined?(:Float)
assert('String#to_i', '15.2.10.5.39') do
a = ''.to_i