@Test public void shouldReturnObjectWriterThatWritesDataSizesInMB() { final DataSize objectToSerialize = DataSize.ofMegabytes(512); String actual; try { actual = getDefaultJsonObjectWriter().writeValueAsString(objectToSerialize); } catch (JsonProcessingException e) { fail(e.getMessage()); actual = ""; } assertThat(actual).describedAs("Serialized form of DataSize").isEqualTo("\"512MB\""); }
public static ObjectWriter getDefaultJsonObjectWriter() { return DEFAULT_JSON_OBJECT_WRITER; }
ObjectWriterFactory { public static ObjectWriter getDefaultJsonObjectWriter() { return DEFAULT_JSON_OBJECT_WRITER; } }
ObjectWriterFactory { public static ObjectWriter getDefaultJsonObjectWriter() { return DEFAULT_JSON_OBJECT_WRITER; }  }
ObjectWriterFactory { public static ObjectWriter getDefaultJsonObjectWriter() { return DEFAULT_JSON_OBJECT_WRITER; }  static ObjectWriter getDefaultJsonObjectWriter(); }
ObjectWriterFactory { public static ObjectWriter getDefaultJsonObjectWriter() { return DEFAULT_JSON_OBJECT_WRITER; }  static ObjectWriter getDefaultJsonObjectWriter();  }