AlertHandler extends ProtocolMessageHandler<AlertMessage> { @Override public AlertSerializer getSerializer(AlertMessage message) { return new AlertSerializer(message, tlsContext.getChooser().getSelectedProtocolVersion()); } AlertHandler(TlsContext tlsContext); @Override AlertParser getParser(byte[] message, int pointer); @Override AlertPreparator getPreparator(AlertMessage message); @Override AlertSerializer getSerializer(AlertMessage message); @Override void adjustTLSContext(AlertMessage message);  }
@Test public void testGetSerializer() { assertTrue(handler.getSerializer(new AlertMessage()) instanceof AlertSerializer); }