Skip to content

Commit 801a4e4

Browse files
kounobu
authored andcommitted
Remove needless + from MatchData#integer_at tests
72eb59d introduced these tests.
1 parent 2ad7886 commit 801a4e4

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

test/ruby/test_regexp.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1694,7 +1694,7 @@ def test_matchdata_large_capture_groups_stack
16941694
end
16951695

16961696
def test_match_integer_at
1697-
m = /(\d+{4})(\d+{2})(\d+{2})/.match("20260308")
1697+
m = /(\d{4})(\d{2})(\d{2})/.match("20260308")
16981698
assert_equal(20260308, m.integer_at(0))
16991699
assert_equal(2026, m.integer_at(1))
17001700
assert_equal(3, m.integer_at(2))
@@ -1711,7 +1711,7 @@ def test_match_integer_at
17111711
end
17121712

17131713
def test_match_integer_at_name
1714-
m = /(?<y>\d+{4})(?<m>\d+{2})(?<d>\d+{2})/.match("20260308")
1714+
m = /(?<y>\d{4})(?<m>\d{2})(?<d>\d{2})/.match("20260308")
17151715
assert_equal(2026, m.integer_at("y"))
17161716
assert_equal(3, m.integer_at("m"))
17171717
assert_equal(8, m.integer_at("d"))

0 commit comments

Comments
 (0)