diff --git a/crates/hir_def/src/macro_expansion_tests/mbe.rs b/crates/hir_def/src/macro_expansion_tests/mbe.rs index 7279ff7e33c..3c5a02ce2e0 100644 --- a/crates/hir_def/src/macro_expansion_tests/mbe.rs +++ b/crates/hir_def/src/macro_expansion_tests/mbe.rs @@ -615,3 +615,23 @@ fn bar() {} "#]], ); } + +#[test] +fn test_macro_2_0_panic_2015() { + check( + r#" +macro panic_2015 { + () => (), + (bar) => (), +} +panic_2015!(bar); +"#, + expect![[r#" +macro panic_2015 { + () => (), + (bar) => (), +} + +"#]], + ); +} diff --git a/crates/mbe/src/tests/expand.rs b/crates/mbe/src/tests/expand.rs index 393c2041d99..758bf8c6f73 100644 --- a/crates/mbe/src/tests/expand.rs +++ b/crates/mbe/src/tests/expand.rs @@ -101,21 +101,6 @@ fn test_attr_to_token_tree() { ); } -#[test] -fn test_macro_2_0_panic_2015() { - parse_macro2( - r#" -macro panic_2015 { - () => ( - ), - (bar) => ( - ), -} -"#, - ) - .assert_expand_items("panic_2015!(bar);", ""); -} - #[test] fn test_path() { parse_macro(