forked from ibanos90/obs2ioda
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added subroutine that parses ctest command line args to determine typ…
…e of test. If the test is a memcheck test, the memcheck assert handler is used, else the standard assert handler is used.
- Loading branch information
Showing
5 changed files
with
92 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,20 @@ | ||
program Test_fortran_test_framework_driver | ||
use Test_fortran_test_framework_mod | ||
use fortran_test_framework_mod, only : assert, assert_memcheck, determine_test_type | ||
implicit none | ||
integer n_args | ||
character(len = 64) :: test_type, arg | ||
integer :: i | ||
procedure(assert_interface), pointer :: assert_proc | ||
|
||
call test_assertEqual_string() | ||
call test_assertEqual_logical() | ||
call test_assertEqual_integer() | ||
call determine_test_type(test_type) | ||
|
||
if (trim(test_type) == "standard") then | ||
assert_proc => assert | ||
else | ||
assert_proc => assert_memcheck | ||
end if | ||
call test_assertEqual_integer(assert_proc) | ||
call test_assertEqual_logical(assert_proc) | ||
call test_assertEqual_string(assert_proc) | ||
end program |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters