Test code relating to COG counters