Refactored the code a little bit and updated the test for changes to the TLS state machine.
------------- Commit messages: - 8298868: Update EngineCloseOnAlert.java for changes to TLS implementation Changes: https://git.openjdk.org/jdk/pull/11903/files Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=11903&range=00 Issue: https://bugs.openjdk.org/browse/JDK-8298868 Stats: 57 lines in 2 files changed: 16 ins; 9 del; 32 mod Patch: https://git.openjdk.org/jdk/pull/11903.diff Fetch: git fetch https://git.openjdk.org/jdk pull/11903/head:pull/11903 PR: https://git.openjdk.org/jdk/pull/11903