ExtendedMasterSecretExtensionSerializer extends ExtensionSerializer<ExtendedMasterSecretExtensionMessage> { @Override public byte[] serializeExtensionContent() { LOGGER.debug("Serialized the extended master secret extension."); return getAlreadySerialized(); } ExtendedMasterSecretExtensionSerializer(ExtendedMasterSecretExtensionMessage message); @Override byte[] serializeExtensionContent();  }
@Test public void testSerializeExtensionContent() { message = new ExtendedMasterSecretExtensionMessage(); message.setExtensionType(extensionType.getValue()); message.setExtensionLength(extensionLength); ExtendedMasterSecretExtensionSerializer serializer = new ExtendedMasterSecretExtensionSerializer(message); assertArrayEquals(expectedBytes, serializer.serialize()); }