From e7387d469502dcc6286a5ef24204d33fc0d198e3 Mon Sep 17 00:00:00 2001 From: ilslv <47687266+ilslv@users.noreply.github.com> Date: Wed, 1 Dec 2021 15:37:20 +0300 Subject: [PATCH] Fix non-deterministic regex capturing group in `writer::JUnit` tests (#170) --- tests/junit.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/junit.rs b/tests/junit.rs index 606d270c..276d7dc7 100644 --- a/tests/junit.rs +++ b/tests/junit.rs @@ -31,7 +31,9 @@ async fn main() { // Required to strip out non-deterministic parts of output, so we could // compare them well. let non_deterministic = Regex::new( - r#"time(stamp)?="[^"]+"|: [\\/:?A-z]+.feature(:\d+:\d+)?|\s?\n"#, + "time(stamp)?=\"[^\"]+\"\ + |: [/\\\\](.*)[/\\\\]([A-z1-9-_]*).feature(:\\d+:\\d+)?\ + |\\s?\n", ) .unwrap();