Skip to content

Add support for regex expressions in expected_output.txt#50

Closed
nickpdemarco wants to merge 1 commit intoHKalbasi:mainfrom
nickpdemarco:regex-expected-output
Closed

Add support for regex expressions in expected_output.txt#50
nickpdemarco wants to merge 1 commit intoHKalbasi:mainfrom
nickpdemarco:regex-expected-output

Conversation

@nickpdemarco
Copy link
Copy Markdown
Contributor

As of (at least) Rust 1.91, thread IDs are printed whenever a thread panics. Since we obviously can't predict those IDs, we have to change how we evaluate example output correctness.

As a quick fix, I added support for regex expressions in expected_output.txt. In this specific case, expected panicking lines can be expressed as:

thread '<unnamed>' ({{re:\d+}}) panicked at examples/simple/src/generated.rs:192:39:

The {{re: ***}} block expresses a regex with contents ***.

@nickpdemarco
Copy link
Copy Markdown
Contributor Author

Closing per discussion here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant