@Override
    public final SSLEngine newEngine(ByteBufAllocator alloc) {
        SSLEngine engine = ctx.newEngine(alloc);
        initEngine(engine);
        return engine;
    }
@Test
    public void testInitEngineOnNewEngine() throws Exception {
        SslContext delegating = newDelegatingSslContext();

        SSLEngine engine = delegating.newEngine(UnpooledByteBufAllocator.DEFAULT);
        assertArrayEquals(EXPECTED_PROTOCOLS, engine.getEnabledProtocols());

        engine = delegating.newEngine(UnpooledByteBufAllocator.DEFAULT, "localhost", 9090);
        assertArrayEquals(EXPECTED_PROTOCOLS, engine.getEnabledProtocols());
    }