mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-22 14:55:26 +00:00
Fix comments around test harness generation
This commit is contained in:
parent
258e3b3a75
commit
7bf33f00bf
@ -327,7 +327,7 @@ fn mk_main(cx: &mut TestCtxt<'_>) -> P<ast::Item> {
|
||||
// Writing this out by hand with 'ignored_span':
|
||||
// pub fn main() {
|
||||
// #![main]
|
||||
// test::test_main_static(::std::os::args().as_slice(), &[..tests]);
|
||||
// test::test_main_static(&[..tests]);
|
||||
// }
|
||||
let sp = ignored_span(cx, DUMMY_SP);
|
||||
let ecx = &cx.ext_cx;
|
||||
|
@ -86,7 +86,7 @@ pub fn expand_test_or_bench(
|
||||
cx.path(sp, vec![test_id, cx.ident_of(name)])
|
||||
};
|
||||
|
||||
// creates test::$name
|
||||
// creates test::ShouldPanic::$name
|
||||
let should_panic_path = |name| {
|
||||
cx.path(sp, vec![test_id, cx.ident_of("ShouldPanic"), cx.ident_of(name)])
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user