summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorStan Lo <stan001212@gmail.com>2023-04-26 17:52:47 +0100
committergit <svn-admin@ruby-lang.org>2023-04-26 16:52:51 +0000
commit92466e440d459cd21e89f8bfbe6d8438bcaa9389 (patch)
tree90c30dd5cbc0cfb1a89a5f57971207ee594d6f15 /test
parent3340a24634ea505c374b677a3cc9061f4428784e (diff)
downloadruby-92466e440d459cd21e89f8bfbe6d8438bcaa9389.tar.gz
[ruby/irb] Use a more tolerant way to check Locale#find's return
path (https://github.com/ruby/irb/pull/572) https://github.com/ruby/irb/commit/0b648adf38
Diffstat (limited to 'test')
-rw-r--r--test/irb/test_locale.rb8
1 files changed, 4 insertions, 4 deletions
diff --git a/test/irb/test_locale.rb b/test/irb/test_locale.rb
index 37f39acf7d..930a38834c 100644
--- a/test/irb/test_locale.rb
+++ b/test/irb/test_locale.rb
@@ -107,12 +107,12 @@ module TestIRB
def test_find
jp_local = IRB::Locale.new("ja_JP.UTF-8")
- path = jp_local.find("irb/error.rb").delete_prefix(Dir.pwd)
- assert_equal("/lib/irb/lc/ja/error.rb", path)
+ path = jp_local.find("irb/error.rb")
+ assert_include(path, "/lib/irb/lc/ja/error.rb")
en_local = IRB::Locale.new("en_US.UTF-8")
- path = en_local.find("irb/error.rb").delete_prefix(Dir.pwd)
- assert_equal("/lib/irb/lc/error.rb", path)
+ path = en_local.find("irb/error.rb")
+ assert_include(path, "/lib/irb/lc/error.rb")
end
end
end