[前][次][番号順一覧][スレッド一覧]

ruby-changes:66576

From: aycabta <ko1@a...>
Date: Wed, 23 Jun 2021 21:00:47 +0900 (JST)
Subject: [ruby-changes:66576] 557b4eb4aa (master): Add detailed message to assert_external_string_equal

https://git.ruby-lang.org/ruby.git/commit/?id=557b4eb4aa

From 557b4eb4aa83f60eacfaae3f5054d78dcc57d1b6 Mon Sep 17 00:00:00 2001
From: aycabta <aycabta@g...>
Date: Wed, 23 Jun 2021 21:00:20 +0900
Subject: Add detailed message to assert_external_string_equal

---
 test/reline/test_history.rb | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/test/reline/test_history.rb b/test/reline/test_history.rb
index 2426d99..5336040 100644
--- a/test/reline/test_history.rb
+++ b/test/reline/test_history.rb
@@ -292,7 +292,8 @@ class Reline::History::Test < Reline::TestCase https://github.com/ruby/ruby/blob/trunk/test/reline/test_history.rb#L292
 
   def assert_external_string_equal(expected, actual)
     assert_equal(expected, actual)
-    assert_equal(get_default_internal_encoding, actual.encoding)
+    mes = "Encoding of #{actual.inspect} is expected #{get_default_internal_encoding.inspect} but #{actual.encoding}"
+    assert_equal(get_default_internal_encoding, actual.encoding, mes)
   end
 
   def get_default_internal_encoding
-- 
cgit v1.1


--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]