### Question:
CorbaObjectWriter { public void writeLong(Integer l) throws CorbaBindingException { if (l == null) { stream.write_long(0); } else { stream.write_long(l.intValue()); } } CorbaObjectWriter(OutputStream outStream); void write(CorbaObjectHandler obj); void writeBoolean(Boolean b); void writeChar(Character c); void writeWChar(Character c); void writeOctet(Byte b); void writeShort(Short s); void writeUShort(Integer s); void writeLong(Integer l); void writeULong(Long l); void writeLongLong(Long l); void writeULongLong(java.math.BigInteger l); void writeFloat(Float f); void writeDouble(Double d); void writeString(String s); void writeWString(String s); void writeAny(CorbaAnyHandler anyHandler); void writeEnum(CorbaEnumHandler enumHandler); void writeStruct(CorbaStructHandler structHandler); void writeException(CorbaExceptionHandler exHandler); void writeFixed(CorbaFixedHandler fixedHandler); void writeUnion(CorbaObjectHandler obj); void writeArray(CorbaArrayHandler arrayHandler); void writeSequence(CorbaObjectHandler obj); void writeObjectReference(CorbaObjectReferenceHandler objHandler);  }### Answer:
@Test public void testWriteLong() { OutputStream oStream = orb.create_output_stream(); CorbaObjectWriter writer = new CorbaObjectWriter(oStream); Integer longValue = Integer.valueOf(-1234567); writer.writeLong(longValue); InputStream iStream = oStream.create_input_stream(); int l = iStream.read_long(); assertTrue(l == longValue.intValue()); }