rust/tests/ui/lint/test-inner-fn.rs
2023-01-11 09:32:08 +00:00

20 lines
336 B
Rust

// compile-flags: --test -D unnameable_test_items
#[test]
fn foo() {
#[test] //~ ERROR cannot test inner items [unnameable_test_items]
fn bar() {}
bar();
}
mod x {
#[test]
fn foo() {
#[test] //~ ERROR cannot test inner items [unnameable_test_items]
fn bar() {}
bar();
}
}
fn main() {}