Cleanup SSL test. (#8301)

Motivation:

I noticed that we had some errors showing up in a test (which did not fail it tho) because we tried to full-fill the promise multiples times.

Modifications:

Use trySuccess(...) as we may produce multiple exceptions.

Result:

Less errors during test-run.
This commit is contained in:
Norman Maurer 2018-09-21 08:04:24 -07:00 committed by GitHub
parent 01db30a163
commit a80c49828f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -340,7 +340,7 @@ public class ParameterizedSslHandlerTest {
public void exceptionCaught(ChannelHandlerContext ctx, Throwable cause) {
if (cause.getCause() instanceof SSLException) {
// We received the alert and so produce an SSLException.
promise.setSuccess(null);
promise.trySuccess(null);
}
}
});