Challenge extends AcmeJsonResource { protected void prepareResponse(JSONBuilder response) { } Challenge(Login login, JSON data); String getType(); Status getStatus(); @Nullable Instant getValidated(); @Nullable Problem getError(); void trigger();  }
@Test public void testRespond() { Challenge challenge = new Challenge(TestUtils.login(), getJSON("genericChallenge")); JSONBuilder response = new JSONBuilder(); challenge.prepareResponse(response); assertThat(response.toString(), sameJSONAs("{}")); }