Skip to content

Commit

Permalink
Issue #8973 - Cleanup KeyStoreScannerTest
Browse files Browse the repository at this point in the history
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
  • Loading branch information
joakime committed Dec 7, 2022
1 parent ad03e45 commit 3f2152e
Showing 1 changed file with 2 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,6 @@
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.condition.DisabledOnOs;
import org.junit.jupiter.api.condition.OS;
import org.junit.jupiter.api.extension.ExtendWith;

import static org.hamcrest.MatcherAssert.assertThat;
Expand Down Expand Up @@ -90,11 +88,6 @@ public void start() throws Exception
}

public void start(Configuration configuration) throws Exception
{
start(configuration, true);
}

public void start(Configuration configuration, boolean resolveAlias) throws Exception
{
SslContextFactory.Server sslContextFactory = new SslContextFactory.Server();
configuration.configure(sslContextFactory);
Expand Down Expand Up @@ -200,7 +193,7 @@ public void testReloadChangingSymbolicLink() throws Exception
sslContextFactory.setKeyStorePath(symlinkKeystorePath.toString());
sslContextFactory.setKeyStorePassword("storepwd");
sslContextFactory.setKeyManagerPassword("keypwd");
}, false);
});

// Check the original certificate expiry.
X509Certificate cert1 = getCertificateFromServer();
Expand Down Expand Up @@ -363,8 +356,6 @@ public void testDoublySymlinkedTimestampedDir() throws Exception
Path targetNov = timestampNovDir.resolve("keystore.p12");
Path targetDec = timestampDecDir.resolve("keystore.p12");

boolean followLinks = false; // follow keystore links

start(sslContextFactory ->
{
// What we want is ..
Expand All @@ -388,7 +379,7 @@ public void testDoublySymlinkedTimestampedDir() throws Exception
sslContextFactory.setKeyStorePath(keystoreLink.toString());
sslContextFactory.setKeyStorePassword("storepwd");
sslContextFactory.setKeyManagerPassword("keypwd");
}, followLinks);
});

// Check the original certificate expiry.
X509Certificate cert1 = getCertificateFromServer();
Expand Down

0 comments on commit 3f2152e

Please sign in to comment.