@Test public void read() throws IOException { final JsonReader reader = mock(JsonReader.class); when(reader.nextString()).thenReturn("b"); assertThat(this.typeAdapter.read(reader), is(SizeUnit.BYTES)); }
@Override public SizeUnit read(final JsonReader in) throws IOException { return Units.size(in.nextString()); }
SizeUnitTypeAdapter extends TypeAdapter<SizeUnit> { @Override public SizeUnit read(final JsonReader in) throws IOException { return Units.size(in.nextString()); } }
SizeUnitTypeAdapter extends TypeAdapter<SizeUnit> { @Override public SizeUnit read(final JsonReader in) throws IOException { return Units.size(in.nextString()); }  }
SizeUnitTypeAdapter extends TypeAdapter<SizeUnit> { @Override public SizeUnit read(final JsonReader in) throws IOException { return Units.size(in.nextString()); }  @Override void write(final JsonWriter out, final SizeUnit value); @Override SizeUnit read(final JsonReader in); }
SizeUnitTypeAdapter extends TypeAdapter<SizeUnit> { @Override public SizeUnit read(final JsonReader in) throws IOException { return Units.size(in.nextString()); }  @Override void write(final JsonWriter out, final SizeUnit value); @Override SizeUnit read(final JsonReader in);  }