module test_ExclusiveColumn use funit use MAPL_Profiler use GFTL_UnlimitedVector contains @test subroutine test_simple() type(MeterNode), target :: node class(AbstractMeterNode), pointer :: subnode class(AbstractMeter), pointer :: t type(ExclusiveColumn) :: c type(UnlimitedVector) :: v integer :: i integer :: expected(3) class(*), allocatable :: q node = MeterNode('top', AdvancedMeter(MpiTimerGauge())) t => node%get_meter() call t%add_cycle(10.0d0) call node%add_child('a', AdvancedMeter(MpiTimerGauge())) subnode => node%get_child('a') t => subnode%get_meter() call t%add_cycle(1.0d0) call node%add_child('b', AdvancedMeter(MpiTimerGauge())) subnode => node%get_child('b') t => subnode%get_meter() call t%add_cycle(2.0d0) v = c%get_rows(node) expected = [7,1,2] do i = 1, 3 q = v%at(i) select type (q) type is (integer) @assertEqual(expected(i), q) end select end do end subroutine test_simple end module test_ExclusiveColumn