Testing of serializing of the object