1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

regex: fix a bug #7559 (#7601)

This commit is contained in:
penguindark
2020-12-27 08:16:00 +01:00
committed by GitHub
parent 1383771423
commit 1b9d514275
2 changed files with 14 additions and 1 deletions

View File

@ -141,6 +141,7 @@ match_test_suite = [
// particular groups
TestItem{"ababababac", r"ab(.*)(ac)",0,10},
]
)
@ -256,6 +257,18 @@ find_all_test_suite = [
r"[Tt]o\w+",
[0, 5, 24, 32],
['Today', 'tomorrow']
},
Test_find_all{
"pera\nurl = https://github.com/dario/pig.html\npippo",
r"url *= *https?://[\w./]+",
[5, 44],
['url = https://github.com/dario/pig.html']
},
Test_find_all{
"pera\nurl = https://github.com/dario/pig.html\npippo",
r"url *= *https?://.*"+'\n',
[5, 45],
['url = https://github.com/dario/pig.html\n']
}
]
)