diff --git a/test/test_description_test.F90 b/test/test_description_test.F90 index e3129950..25aa2fb1 100644 --- a/test/test_description_test.F90 +++ b/test/test_description_test.F90 @@ -116,22 +116,34 @@ logical function tautology() function check_substring_search() result(tests_pass) logical, allocatable :: tests_pass(:) - type(test_description_t), allocatable :: test_descriptions(:) - associate(test_descriptions => [ & +#if ! HAVE_PROCEDURE_ACTUAL_FOR_POINTER_DUMMY + + procedure(test_function_i), pointer :: null_ptr + null_ptr => null() + + test_descriptions = [ & + test_description_t("an example substring" , null_ptr) & + ,test_description_t("another example substring", null_ptr) & + ,test_description_t("moving right along" , null_ptr) & + ,test_description_t("nothing to see here" , null_ptr) & + ] +#else + + test_descriptions = [ & test_description_t("an example substring" , null()) & ,test_description_t("another example substring", null()) & ,test_description_t("moving right along" , null()) & ,test_description_t("nothing to see here" , null()) & - ]) + ] +#endif tests_pass = [ & test_descriptions(1)%contains_text(string_t("example") ) & , test_descriptions(2)%contains_text( "example" ) & ,.not. test_descriptions(3)%contains_text(string_t("missing string")) & ,.not. test_descriptions(4)%contains_text( "missing string" ) & ] - end associate end function end module test_description_test_m