1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
|
program stop_with_integer_code
use iso_c_binding, only: c_bool
use prif, only : &
prif_init &
,prif_stop &
,prif_error_stop
use unit_test_parameters_m, only : expected_stop_code
implicit none
integer init_exit_code
logical(kind=c_bool), parameter :: false = .false._c_bool
call prif_init(init_exit_code)
call prif_stop(quiet=false, stop_code_int=expected_stop_code) ! a prif_stop unit test passes if this line executes normal termination
call prif_error_stop(quiet=false) ! a prif_stop unit test fails if this line runs
end program
|