Skip to content

Commit

Permalink
ZOOKEEPER-236. Added cipher suite to test to run on CentOS. Timeout i…
Browse files Browse the repository at this point in the history
…n constant value. Null checks
  • Loading branch information
anmolnar committed Jul 31, 2018
1 parent c452d1b commit ed10e88
Showing 1 changed file with 10 additions and 9 deletions.
19 changes: 10 additions & 9 deletions src/java/test/org/apache/zookeeper/test/QuorumSSLTest.java
Expand Up @@ -147,15 +147,11 @@ public class QuorumSSLTest extends QuorumPeerTestBase {
private Date certStartTime;
private Date certEndTime;

private int originalTimeout;

@Rule
public Timeout timeout = Timeout.builder().withTimeout(5, TimeUnit.MINUTES).withLookingForStuckThread(true).build();

@Before
public void setup() throws Exception {
originalTimeout = CONNECTION_TIMEOUT;
CONNECTION_TIMEOUT = 5000;
ClientBase.setupTestEnv();

tmpDir = createTmpDir().getAbsolutePath();
Expand Down Expand Up @@ -372,11 +368,16 @@ public void setSSLSystemProperties() {

@After
public void cleanUp() throws Exception {
CONNECTION_TIMEOUT = originalTimeout;
clearSSLSystemProperties();
q1.shutdown();
q2.shutdown();
q3.shutdown();
if (q1 != null) {
q1.shutdown();
}
if (q2 != null) {
q2.shutdown();
}
if (q3 != null) {
q3.shutdown();
}

Security.removeProvider("BC");
}
Expand Down Expand Up @@ -679,7 +680,7 @@ public void testOCSP() throws Exception {
@Test
public void testCipherSuites() throws Exception {
System.setProperty(quorumX509Util.getCipherSuitesProperty(),
"SSL_DHE_RSA_WITH_3DES_EDE_CBC_SHA,SSL_RSA_WITH_RC4_128_MD5");
"SSL_DHE_RSA_WITH_3DES_EDE_CBC_SHA,SSL_RSA_WITH_RC4_128_MD5,SSL_DHE_RSA_WITH_DES_CBC_SHA");

q1 = new MainThread(1, clientPortQp1, quorumConfiguration, SSL_QUORUM_ENABLED);
q2 = new MainThread(2, clientPortQp2, quorumConfiguration, SSL_QUORUM_ENABLED);
Expand Down

0 comments on commit ed10e88

Please sign in to comment.