Skip to content

Ensure assert_eq_unordered panics display the line on which they were called - #3

Open
uckelman wants to merge 1 commit into
nu11ptr:masterfrom
uckelman:track_caller
Open

Ensure assert_eq_unordered panics display the line on which they were called#3
uckelman wants to merge 1 commit into
nu11ptr:masterfrom
uckelman:track_caller

Conversation

@uckelman

Copy link
Copy Markdown

The assert_eq_unordered macros display the line where panic! is called inside the assert_unordered crate. This isn't the most helpful information when you have several unordered assertions that could be failing.

This PR adds #[track_caller] to functions called on the way to panics; this way, a failing assert_eq_unordered macro backtrace will list the line where the macro was called, just like assert_eq! does.

a failing assert_eq_unordered* macro backtrace will list the line where
the macro was called, just like assert_eq! does.
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