Copy pasted this example from above. This is to test both when you pass in `valid` to `new_key_record` and when you don't.