1
0
mirror of synced 2026-08-31 14:35:18 +00:00

Test Jackson 2 deserializer with unknown primitive WebAuthn ext

Signed-off-by: Ziqin Wang <ziqin@wangziqin.net>
This commit is contained in:
Ziqin Wang
2026-03-15 12:30:13 +08:00
parent 88ea668f47
commit a7039fb3e6
@@ -122,6 +122,23 @@ class JacksonTests {
assertThat(outputs).usingRecursiveComparison().isEqualTo(credProps);
}
@Test
void readAuthenticationExtensionsClientOutputsWhenAppId() throws Exception {
String json = """
{
"appid": false,
"credProps": {
"rk": false
}
}
""";
CredentialPropertiesOutput credProps = new CredentialPropertiesOutput(false);
AuthenticationExtensionsClientOutputs outputs = this.mapper.readValue(json,
AuthenticationExtensionsClientOutputs.class);
assertThat(outputs.getOutputs()).usingRecursiveFieldByFieldElementComparator().contains(credProps);
}
@Test
void readAuthenticationExtensionsClientOutputsWhenUnknownExtension() throws Exception {
String json = """