test_do_not_reuse_regridder Subroutine

public subroutine test_do_not_reuse_regridder(this)

Arguments

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

Calls

proc~~test_do_not_reuse_regridder~~CallsGraph proc~test_do_not_reuse_regridder test_do_not_reuse_regridder ESMF_HConfigCreate ESMF_HConfigCreate proc~test_do_not_reuse_regridder->ESMF_HConfigCreate anyexceptions anyexceptions proc~test_do_not_reuse_regridder->anyexceptions assert_that assert_that proc~test_do_not_reuse_regridder->assert_that assertfalse assertfalse proc~test_do_not_reuse_regridder->assertfalse esmfregridderparam esmfregridderparam proc~test_do_not_reuse_regridder->esmfregridderparam geommanager geommanager proc~test_do_not_reuse_regridder->geommanager none~get_regridder RegridderManager%get_regridder proc~test_do_not_reuse_regridder->none~get_regridder proc~make_geom~5 make_geom proc~test_do_not_reuse_regridder->proc~make_geom~5 sourcelocation sourcelocation proc~test_do_not_reuse_regridder->sourcelocation find find none~get_regridder->find none~add_regridder RegridderManager%add_regridder none~get_regridder->none~add_regridder none~back~8 RegridderVector%back none~get_regridder->none~back~8 none~begin~141 RegridderSpecVector%begin none~get_regridder->none~begin~141 none~make_regridder~3 RegridderManager%make_regridder none~get_regridder->none~make_regridder~3 none~of~25 RegridderVector%of none~get_regridder->none~of~25 proc~mapl_return MAPL_Return none~get_regridder->proc~mapl_return proc~mapl_verify MAPL_Verify none~get_regridder->proc~mapl_verify proc~make_geom~5->ESMF_HConfigCreate get_geom get_geom proc~make_geom~5->get_geom get_mapl_geom get_mapl_geom proc~make_geom~5->get_mapl_geom none~push_back~41 RegridderSpecVector%push_back none~add_regridder->none~push_back~41 none~make_regridder~3->proc~mapl_return none~make_regridder~3->proc~mapl_verify interface~mapl_assert MAPL_Assert none~make_regridder~3->interface~mapl_assert none~get_param RegridderSpec%get_param none~make_regridder~3->none~get_param none~make_regridder~4 RegridderFactory%make_regridder none~make_regridder~3->none~make_regridder~4 none~of~158 RegridderFactoryVector%of none~make_regridder~3->none~of~158 supports supports none~make_regridder~3->supports none~of_size_kind~3 RegridderVector%of_size_kind none~of~25->none~of_size_kind~3 at at proc~mapl_return->at insert insert proc~mapl_return->insert proc~mapl_throw_exception MAPL_throw_exception proc~mapl_return->proc~mapl_throw_exception proc~mapl_verify->proc~mapl_throw_exception

Source Code

   subroutine test_do_not_reuse_regridder(this)
      class(ESMF_TestMethod), intent(inout) :: this
      type(GeomManager) :: geom_mgr
      type(RegridderManager), target :: regridder_mgr
      type(RegridderSpec) :: spec_1, spec_2
      integer :: status
      class(Regridder), pointer :: regridder_1, regridder_2
      type(ESMF_Geom) :: geom_1, geom_2
      type(ESMF_HConfig) :: hconfig

      geom_mgr = GeomManager()
      regridder_mgr = RegridderManager()

      geom_1 = make_geom(geom_mgr, _RC)

      hconfig = ESMF_HConfigCreate(content="{class: latlon, im_world: 12, jm_world: 11, pole: PC, dateline: DC, nx: 1, ny: 1}", _RC)
      geom_2 = make_geom(geom_mgr, hconfig, _RC) ! variant of geom_1

      
      spec_1 = RegridderSpec(EsmfRegridderParam(), geom_1, geom_1)
      regridder_1 => regridder_mgr%get_regridder(spec_1, _RC)

      spec_2 = RegridderSpec(EsmfRegridderParam(), geom_1, geom_2)
      regridder_2 => regridder_mgr%get_regridder(spec_2, _RC)

      @assertFalse(associated(regridder_1, regridder_2))
   end subroutine test_do_not_reuse_regridder