Validate keys before testing them.