### Question:
TextExpression implements Distributable { @Override public Map<String, Object> serialize() { Map<String, Object> theResult = new HashMap<>(); theResult.put("expression", expression); return theResult; } TextExpression(String aExpression); String get(); @Override boolean equals(Object o); @Override int hashCode(); @Override Map<String, Object> serialize(); static TextExpression deserialize(Map<String,Object> aSerializedData); final String expression; }### Answer:
@Test public void testSerialize() throws Exception { TextExpression theExpression = new TextExpression("test"); Map<String, Object> theData = theExpression.serialize(); assertEquals(1, theData.size()); assertEquals("test", theData.get("expression")); }