Skip to content

Commit c44d228

Browse files
committed
expr: Test $ at the end of a subpattern
1 parent 7aa3356 commit c44d228

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

tests/by-util/test_expr.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -298,6 +298,10 @@ fn test_regex() {
298298
.args(&["a", ":", "a$\\|b"])
299299
.succeeds()
300300
.stdout_only("1\n");
301+
new_ucmd!()
302+
.args(&["ab", ":", "a\\(b$\\)"])
303+
.succeeds()
304+
.stdout_only("b\n");
301305
new_ucmd!()
302306
.args(&["abc", ":", "^abc"])
303307
.succeeds()

0 commit comments

Comments
 (0)