  @Test
  public void qualifierWithElements() throws IOException {

    Moshi moshi = new Moshi.Builder().add(LocalizedBooleanAdapter.FACTORY).build();

    Baguette baguette = new Baguette();
    baguette.avecBeurre = true;
    baguette.withButter = true;

    JsonAdapter<Baguette> adapter = moshi.adapter(Baguette.class);
    assertThat(adapter.toJson(baguette))
        .isEqualTo("{\"avecBeurre\":\"oui\",\"withButter\":\"yes\"}");

    Baguette decoded = adapter.fromJson("{\"avecBeurre\":\"oui\",\"withButter\":\"yes\"}");
    assertThat(decoded.avecBeurre).isTrue();
    assertThat(decoded.withButter).isTrue();
  }