diff options
author | Kevin Newton <[email protected]> | 2024-05-29 10:12:51 -0400 |
---|---|---|
committer | Kevin Newton <[email protected]> | 2024-05-30 15:18:20 -0400 |
commit | 72452f43871b8034bfa718ed823bc62b5b81d6f9 (patch) | |
tree | 1bd87295dfcf10d20bce7f6d18184644bb079387 /test/prism/regexp_test.rb | |
parent | 1ab7c412d2e3880a7ad233c32e93961888f8145c (diff) |
[ruby/prism] Tests overhaul
https://github.com/ruby/prism/commit/6f886be0a4
Diffstat (limited to 'test/prism/regexp_test.rb')
-rw-r--r-- | test/prism/regexp_test.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/test/prism/regexp_test.rb b/test/prism/regexp_test.rb index 35be217f79..297020fc72 100644 --- a/test/prism/regexp_test.rb +++ b/test/prism/regexp_test.rb @@ -223,12 +223,12 @@ module Prism def test_last_encoding_option_wins regex = "/foo/nu" - option = Prism.parse(regex).value.statements.body.first.options + option = Prism.parse_statement(regex).options assert_equal Regexp::FIXEDENCODING, option regex = "/foo/un" - option = Prism.parse(regex).value.statements.body.first.options + option = Prism.parse_statement(regex).options assert_equal Regexp::NOENCODING, option end @@ -246,7 +246,7 @@ module Prism def options(flags) options = ["/foo/#{flags}", "/foo\#{1}/#{flags}"].map do |source| - Prism.parse(source).value.statements.body.first.options + Prism.parse_statement(source).options end # Check that we get the same set of options from both regular expressions |