Fix some tests on the opaque keys branch