]>
git.proxmox.com Git - rustc.git/blob - src/test/ui/test-attrs/test-panic-abort.rs
2 // compile-flags: --test -Cpanic=abort -Zpanic_abort_tests
3 // run-flags: --test-threads=1
6 // exec-env:RUST_BACKTRACE=0
7 // normalize-stdout-test "finished in \d+\.\d+s" -> "finished in $$TIME"
9 // ignore-wasm no panic or subprocess support
10 // ignore-emscripten no panic or subprocess support
11 // ignore-sgx no subprocess support
31 println
!("hello, world");
32 writeln
!(std
::io
::stdout(), "testing123").unwrap();
33 writeln
!(std
::io
::stderr(), "testing321").unwrap();
39 std
::process
::exit(123);
43 fn no_residual_environment() {
44 for (key
, _
) in env
::vars() {
45 // Look for keys like __RUST_TEST_INVOKE.
46 if key
.contains("TEST_INVOKE") {
47 panic
!("shouldn't have '{}' in environment", key
);