Handle last generated key when no key has been generated (in H2)
Simplify tests