Skip to content

Commit 853067e

Browse files
committed
add validation for regex flags
1 parent eb9c01b commit 853067e

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

features/db-search.feature

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -701,6 +701,9 @@ Feature: Search through the database
701701
When I run `wp db search 'unfindable' --regex`
702702
Then STDOUT should be empty
703703

704+
When I run `wp db search 'unfindable' --regex --regex-flags='abcd'`
705+
Then the return code should be 1
706+
704707
When I run `wp db search '[0-9é]+?https:' --regex --regex-flags=u --before_context=0 --after_context=0`
705708
Then STDOUT should contain:
706709
"""

0 commit comments

Comments
 (0)