test_equal_dims Subroutine

public subroutine test_equal_dims()

Arguments

None

Calls

proc~~test_equal_dims~~CallsGraph proc~test_equal_dims test_equal_dims assertfalse assertfalse proc~test_equal_dims->assertfalse asserttrue asserttrue proc~test_equal_dims->asserttrue none~add_dimension FileMetadata%add_dimension proc~test_equal_dims->none~add_dimension insert insert none~add_dimension->insert interface~mapl_assert MAPL_Assert none~add_dimension->interface~mapl_assert none~get_dimension FileMetadata%get_dimension none~add_dimension->none~get_dimension none~has_dimension FileMetadata%has_dimension none~add_dimension->none~has_dimension proc~mapl_return MAPL_Return none~add_dimension->proc~mapl_return none~get_dimension->proc~mapl_return at at none~get_dimension->at find find none~get_dimension->find none~has_dimension->proc~mapl_return none~has_dimension->find proc~mapl_return->insert proc~mapl_return->at proc~mapl_throw_exception MAPL_throw_exception proc~mapl_return->proc~mapl_throw_exception

Source Code

   subroutine test_equal_dims()

      type (FileMetadata) :: cf1
      type (FileMetadata) :: cf2

      @assertTrue(cf1 == cf2)
      @assertFalse(cf1 /= cf2)

      call cf1%add_dimension('x', 10)
      call cf1%add_dimension('t', pFIO_UNLIMITED)

      call cf2%add_dimension('t', pFIO_UNLIMITED)
      call cf2%add_dimension('x', 10)
      @assertTrue(cf1 == cf2)
      @assertFalse(cf1 /= cf2)

      call cf1%add_dimension('z', 5)
      @assertFalse(cf1 == cf2)
      @assertFalse(cf2 == cf1)

   end subroutine test_equal_dims