LoginRequest { @JsonCreator public static LoginRequest from( @JsonProperty(value="username", required=true) String username, @JsonProperty(value = "password", required=true) char[] password) { return new AutoValue_LoginRequest(username, password); }  @JsonCreator static LoginRequest from(
      @JsonProperty(value="username", required=true) String username, @JsonProperty(value = "password", required=true) char[] password); @JsonProperty abstract String username(); @JsonProperty abstract char[] password(); @Override String toString();  }
@Test public void deserializesCorrectly() throws Exception { LoginRequest loginRequest = LoginRequest.from("keywhizAdmin", "adminPass".toCharArray()); assertThat(fromJson(jsonFixture("fixtures/loginRequest.json"), LoginRequest.class)) .isEqualTo(loginRequest); }