Skip to content

Commit

Permalink
tests: added test for demoing capture names
Browse files Browse the repository at this point in the history
See also: #399
  • Loading branch information
fulara authored and BurntSushi committed Dec 30, 2017
1 parent fd11756 commit 75907d5
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions tests/replace.rs
Original file line number Diff line number Diff line change
Expand Up @@ -39,3 +39,6 @@ replace!(match_at_start_replace_with_empty, replace_all, r"foo", "foobar", t!(""

// See https://github.com/rust-lang/regex/issues/393
replace!(single_empty_match, replace, r"^", "bar", t!("foo"), "foobar");

// See https://github.com/rust-lang/regex/issues/399
replace!(capture_longest_possible_name, replace_all, r"(.)", "b", t!("${1}a $1a"), "ba ");

0 comments on commit 75907d5

Please sign in to comment.