File tree Expand file tree Collapse file tree 2 files changed +2
-4
lines changed Expand file tree Collapse file tree 2 files changed +2
-4
lines changed Original file line number Diff line number Diff line change @@ -836,8 +836,7 @@ fn run_test(
836
836
match result {
837
837
Err ( e) => return ( duration, Err ( TestFailure :: ExecutionError ( e) ) ) ,
838
838
Ok ( out) => {
839
- // FIXME: use test::ERROR_EXIT_CODE once public
840
- if langstr. should_panic && out. status . code ( ) != Some ( 101 ) {
839
+ if langstr. should_panic && out. status . code ( ) != Some ( test:: ERROR_EXIT_CODE ) {
841
840
return ( duration, Err ( TestFailure :: UnexpectedRunPass ) ) ;
842
841
} else if !langstr. should_panic && !out. status . success ( ) {
843
842
return ( duration, Err ( TestFailure :: ExecutionFailure ( out) ) ) ;
Original file line number Diff line number Diff line change @@ -143,8 +143,7 @@ mod __doctest_mod {{
143
143
.output()
144
144
.expect(\" failed to run command\" );
145
145
if should_panic {{
146
- // FIXME: use test::ERROR_EXIT_CODE once public
147
- if out.status.code() != Some(101) {{
146
+ if out.status.code() != Some(test::ERROR_EXIT_CODE) {{
148
147
eprintln!(\" Test didn't panic, but it's marked `should_panic`.\" );
149
148
ExitCode::FAILURE
150
149
}} else {{
You can’t perform that action at this time.
0 commit comments