public void validate() throws Exception {
      ByteArrayInputStream bais = new ByteArrayInputStream(deserialized);
      DataInputStream dis = new DataInputStream(bais);
      Object v = DataSerializer.readObject(dis);
      if (!(v instanceof WOABA2)) {
        fail("expected instance of WOABA2 but found " + v.getClass());
      }
      f = (WOABA2) v;
    }
Tests data serializing a {@link Boolean} using {@link DataSerializer#writeObject}.
geode-core/src/test/java/org/apache/geode/internal/DataSerializableJUnitTest.java