We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 63e8214 commit d947398Copy full SHA for d947398
1 file changed
crates/libtest2/src/macros.rs
@@ -110,7 +110,9 @@ macro_rules! _test_parse {
110
fn name(&self) -> &str {
111
$crate::_private::push!(crate::TESTS, _: $crate::_private::DynCase = $crate::_private::DynCase(&$name));
112
113
- stringify!($name)
+ const FULL_PATH: &str = concat!(std::module_path!(), "::", stringify!($name));
114
+ let i = FULL_PATH.find("::").expect("we have inserted this in the line above so it must be there");
115
+ &FULL_PATH[(i+2)..]
116
}
117
fn kind(&self) -> $crate::_private::TestKind {
118
Default::default()
0 commit comments