Skip to content

Commit 9d774f8

Browse files
committed
SNI fixes
1 parent e865263 commit 9d774f8

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

quickfixj-core/src/test/java/quickfix/mina/ssl/SSLCertificateTest.java

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,9 @@
2424
import org.burningwave.tools.net.DefaultHostResolver;
2525
import org.burningwave.tools.net.HostResolutionRequestInterceptor;
2626
import org.burningwave.tools.net.MappedHostResolver;
27+
import org.junit.AfterClass;
2728
import org.junit.Before;
29+
import org.junit.BeforeClass;
2830
import org.junit.Test;
2931
import org.junit.runner.RunWith;
3032
import org.junit.runners.Parameterized;
@@ -95,14 +97,19 @@ public SSLCertificateTest(String enabledCipherSuites, String enabledProtocols) {
9597
this.enabledProtocols = enabledProtocols;
9698
}
9799

98-
@Before
99-
public void setUp() {
100+
@BeforeClass
101+
public static void setUpClass() {
100102
Map<String, String> hostAliases = new HashMap<>();
101103
hostAliases.put(LOCALHOST_ALIAS, "127.0.0.1");
102104

103105
HostResolutionRequestInterceptor.INSTANCE.install(new MappedHostResolver(hostAliases), DefaultHostResolver.INSTANCE);
104106
}
105107

108+
@AfterClass
109+
public static void tearDownClass() {
110+
HostResolutionRequestInterceptor.INSTANCE.uninstall();
111+
}
112+
106113
@After
107114
public void tearDown() {
108115
try {

0 commit comments

Comments
 (0)