RegisterRequest extends JsonSerializable implements Persistable { public static RegisterRequest fromJson(String json) throws U2fBadInputException { return fromJson(json, RegisterRequest.class); } RegisterRequest(String challenge, String appId); @Override String getRequestId(); static RegisterRequest fromJson(String json);  }
@Test public void testJavaSerializer() throws Exception { RegisterRequest registerRequest = RegisterRequest.fromJson(JSON); RegisterRequest registerRequest2 = TestUtils.clone(registerRequest); assertEquals(registerRequest, registerRequest2); }