assert_equal_c32_1 Subroutine

private subroutine assert_equal_c32_1(this, c1, c2)

Check if two complex (32 bits) arrays (rank 1) are equal.

Type Bound

tester_t

Arguments

Type IntentOptional Attributes Name
class(tester_t), intent(inout) :: this

The tester.

complex(kind=real32), intent(in), dimension(:) :: c1

Value to compare.

complex(kind=real32), intent(in), dimension(:) :: c2

Value to compare.


Called by

proc~~assert_equal_c32_1~~CalledByGraph proc~assert_equal_c32_1 tester::tester_t%assert_equal_c32_1 none~assert_equal tester::tester_t%assert_equal none~assert_equal->proc~assert_equal_c32_1 program~flap_test_group flap_test_group program~flap_test_group->none~assert_equal program~test_tester_05 test_tester_05 program~test_tester_05->none~assert_equal program~test_tester_1 test_tester_1 program~test_tester_1->none~assert_equal program~test_tester_1~2 test_tester_1 program~test_tester_1~2->none~assert_equal program~test_tester_2 test_tester_2 program~test_tester_2->none~assert_equal program~test_tester_3 test_tester_3 program~test_tester_3->none~assert_equal program~test_tester_4 test_tester_4 program~test_tester_4->none~assert_equal program~test_tester_7 test_tester_7 program~test_tester_7->none~assert_equal program~test_tester_8 test_tester_8 program~test_tester_8->none~assert_equal

Source Code

  subroutine assert_equal_c32_1(this, c1, c2)
    class(tester_t),               intent(inout)        :: this !< The tester.
    complex(real32), dimension(:), intent(in)           :: c1   !< Value to compare.
    complex(real32), dimension(:), intent(in)           :: c2   !< Value to compare.

    this% n_tests = this% n_tests + 1

    if ( size(c1) .ne. size(c2) ) then
       this% n_errors = this% n_errors + 1
    else
       if ( maxval(abs(c1-c2)) > 0 ) then
          this% n_errors = this% n_errors + 1
       end if
    end if

  end subroutine assert_equal_c32_1