Add extra check in stats retrieval in test