Added fix for failing ApiKey tests