diff options
author | Nobuyoshi Nakada <[email protected]> | 2022-08-18 23:42:53 +0900 |
---|---|---|
committer | Nobuyoshi Nakada <[email protected]> | 2022-08-19 01:28:31 +0900 |
commit | d903e7672637d5a834847820a4e18b00ee30f380 () | |
tree | e9ac8cbf0b9c2833446987acdae4c038e0e6ac31 /tool/lib/core_assertions.rb | |
parent | 8c44b07fa4b37f3c2a382e11978b743053093159 (diff) |
Allow strings in assert_pattern_list
Notes: Merged: https://.com/ruby/ruby/pull/6252
-rw-r--r-- | tool/lib/core_assertions.rb | 10 |
1 files changed, 6 insertions, 4 deletions
@@ -548,11 +548,13 @@ eom anchored = false else if anchored - match = /\A#{pattern}/.match(rest) else - match = pattern.match(rest) end - unless match msg = message(msg) { expect_msg = "Expected #{mu_pp pattern}\n" if /\n[^\n]/ =~ rest @@ -569,7 +571,7 @@ eom } assert false, msg end - rest = match.post_match anchored = true end } |