summaryrefslogtreecommitdiff
path: root/test/ruby/test_string.rb
diff options
context:
space:
mode:
authorNobuyoshi Nakada <[email protected]>2023-12-16 13:48:49 +0900
committerNobuyoshi Nakada <[email protected]>2023-12-16 16:00:12 +0900
commitb710f96b5aaeb6c153e4b1a7e1b46c4521214126 (patch)
tree482638479eea7df6f5a9602432704628869250c0 /test/ruby/test_string.rb
parentdd49ee152ba4153f5c4cf44896975cf1e0ee739e (diff)
[Bug #20068] Encoding does not matter to empty strings
Diffstat (limited to 'test/ruby/test_string.rb')
-rw-r--r--test/ruby/test_string.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/test/ruby/test_string.rb b/test/ruby/test_string.rb
index 1c7e085630..4d5dea7328 100644
--- a/test/ruby/test_string.rb
+++ b/test/ruby/test_string.rb
@@ -1344,6 +1344,7 @@ CODE
assert_not_equal(S("a").hash, S("a\0").hash, bug4104)
bug9172 = '[ruby-core:58658] [Bug #9172]'
assert_not_equal(S("sub-setter").hash, S("discover").hash, bug9172)
+ assert_equal(S("").hash, S("".encode(Encoding::UTF_32BE)).hash)
end
def test_hex