julienne_test_m Module

Define an abstract test_t type with deferred bindings ("subject" and "results") used by a type-bound procedure ("report") for reporting test results. The "report" procedure thus represents an implementation of the Template Method pattern.


Uses

  • module~~julienne_test_m~~UsesGraph module~julienne_test_m julienne_test_m module~julienne_command_line_m julienne_command_line_m module~julienne_test_m->module~julienne_command_line_m module~julienne_test_result_m julienne_test_result_m module~julienne_test_m->module~julienne_test_result_m module~julienne_user_defined_collectives_m julienne_user_defined_collectives_m module~julienne_test_m->module~julienne_user_defined_collectives_m module~julienne_string_m julienne_string_m module~julienne_test_result_m->module~julienne_string_m module~julienne_test_diagnosis_m julienne_test_diagnosis_m module~julienne_test_result_m->module~julienne_test_diagnosis_m iso_c_binding iso_c_binding module~julienne_string_m->iso_c_binding module~julienne_test_diagnosis_m->module~julienne_string_m

Used by

  • module~~julienne_test_m~~UsedByGraph module~julienne_test_m julienne_test_m module~julienne_m julienne_m module~julienne_m->module~julienne_test_m module~julienne_test_s julienne_test_s module~julienne_test_s->module~julienne_test_m program~assertions assertions program~assertions->module~julienne_m program~check_for_command_line_argument check_for_command_line_argument program~check_for_command_line_argument->module~julienne_m program~get_command_line_flag_value get_command_line_flag_value program~get_command_line_flag_value->module~julienne_m

Variables

Type Visibility Attributes Name Initial
character(len=:), public, allocatable :: test_description_substring

Interfaces

interface

  • private module subroutine report(test, passes, tests, skips)

    Print the test results and increment the tallies of passing tests, total tests, and skipped tests.

    Arguments

    Type IntentOptional Attributes Name
    class(test_t), intent(in) :: test
    integer, intent(inout) :: passes
    integer, intent(inout) :: tests
    integer, intent(inout) :: skips

Abstract Interfaces

abstract interface

  • private function results_interface() result(test_results)

    The result is an array of test results for subsequent reporting in the "report" type-bound procedure

    Arguments

    None

    Return Value type(test_result_t), allocatable, (:)

abstract interface

  • private pure function subject_interface() result(specimen_description)

    The result is the name of the test specimen (the subject of testing)

    Arguments

    None

    Return Value character(len=:), allocatable


Derived Types

type, public, abstract ::  test_t

Facilitate testing and test reporting

Type-Bound Procedures

procedure, public :: report
procedure(results_interface), public, deferred, nopass :: results
procedure(subject_interface), public, deferred, nopass :: subject