@Test
public void shouldCorrectlyWriteObjectId() {

    ObjectId id = new ObjectId(300, 200, 9, 15);
    String expected = "{ \"$oid\" : \"0000012c0000c8000900000f\" }";
    String actual = writer.write(id);
    assertSame(expected, actual);
}