GenericWritable implements Writable, Configurable { public Writable get() { return instance; }  void set(Writable obj); Writable get(); @Override String toString(); @Override void readFields(DataInput in); @Override void write(DataOutput out); @Override Configuration getConf(); @Override void setConf(Configuration conf);  }
@Test public void testGet() throws Exception { Foo foo = new Foo(); FooGenericWritable generic = new FooGenericWritable(); generic.set(foo); assertEquals(foo, generic.get()); }