### Question:
SPPDecoder implements MALDecoder { @Override public Long decodeNullableLong() throws MALException { return isNull() ? null : decodeLong(); } SPPDecoder(final InputStream inputStream, final Map properties); @Override Boolean decodeBoolean(); @Override Boolean decodeNullableBoolean(); @Override Float decodeFloat(); @Override Float decodeNullableFloat(); @Override Double decodeDouble(); @Override Double decodeNullableDouble(); @Override Byte decodeOctet(); @Override Byte decodeNullableOctet(); @Override UOctet decodeUOctet(); @Override UOctet decodeNullableUOctet(); @Override Short decodeShort(); @Override Short decodeNullableShort(); @Override UShort decodeUShort(); @Override UShort decodeNullableUShort(); @Override Integer decodeInteger(); @Override Integer decodeNullableInteger(); @Override UInteger decodeUInteger(); @Override UInteger decodeNullableUInteger(); @Override Long decodeLong(); @Override Long decodeNullableLong(); @Override ULong decodeULong(); @Override ULong decodeNullableULong(); @Override String decodeString(); @Override String decodeNullableString(); @Override Blob decodeBlob(); @Override Blob decodeNullableBlob(); @Override Duration decodeDuration(); @Override Duration decodeNullableDuration(); @Override FineTime decodeFineTime(); @Override FineTime decodeNullableFineTime(); @Override Identifier decodeIdentifier(); @Override Identifier decodeNullableIdentifier(); @Override Time decodeTime(); @Override Time decodeNullableTime(); @Override URI decodeURI(); @Override URI decodeNullableURI(); @Override Element decodeElement(final Element element); @Override Element decodeNullableElement(final Element element); @Override Attribute decodeAttribute(); @Override Attribute decodeNullableAttribute(); @Override MALListDecoder createListDecoder(final List list);  }### Answer:
@Test public void testDecodeNullableLong1() throws Exception { newBuffer(new byte[]{0}); assertEquals(null, decoder.decodeNullableLong()); }
@Test public void testDecodeNullableLong2() throws Exception { newBuffer(new byte[]{ 0, 1, (byte) 0b11111110, (byte) 0xFF, (byte) 0xFF, (byte) 0xFF, (byte) 0xFF, (byte) 0xFF, (byte) 0xFF, (byte) 0xFF, (byte) 0xFF, (byte) 0b00000001, 1, (byte) 0b00000001, 1, (byte) 0b10111110, (byte) 0b11001110, (byte) 0b10010111, (byte) 0b10111111, (byte) 0b11100100, (byte) 0b00000111 }); assertEquals(null, decoder.decodeNullableLong()); assertEquals(Long.valueOf(9223372036854775807L), decoder.decodeNullableLong()); assertEquals(Long.valueOf(-1), decoder.decodeNullableLong()); assertEquals(Long.valueOf(133747110815L), decoder.decodeNullableLong()); }
@Test public void testDecodeNullableLong2b() throws Exception { newBuffer(new byte[]{ 0, 1, (byte) 0x7F, (byte) 0xFF, (byte) 0xFF, (byte) 0xFF, (byte) 0xFF, (byte) 0xFF, (byte) 0xFF, (byte) 0xFF, 1, (byte) 0xFF, (byte) 0xFF, (byte) 0xFF, (byte) 0xFF, (byte) 0xFF, (byte) 0xFF, (byte) 0xFF, (byte) 0xFF, 1, 0, 0, 0, (byte) 0x1F, (byte) 0x23, (byte) 0xF2, (byte) 0xF3, (byte) 0x9F }); setVarintSupportedProperty(false); assertEquals(null, decoder.decodeNullableLong()); assertEquals(Long.valueOf(9223372036854775807L), decoder.decodeNullableLong()); assertEquals(Long.valueOf(-1), decoder.decodeNullableLong()); assertEquals(Long.valueOf(133747110815L), decoder.decodeNullableLong()); }