@@ -0,0 +1,1719 @@
+package de.alpharogroup.crypto.factories;%0A%0Aimport java.io.File;%0Aimport java.io.FileNotFoundException;%0Aimport java.io.IOException;%0Aimport java.security.KeyStore;%0Aimport java.security.KeyStoreException;%0Aimport java.security.NoSuchAlgorithmException;%0Aimport java.security.cert.CertificateException;%0A%0Aimport org.testng.AssertJUnit;%0Aimport org.testng.annotations.Test;%0A%0Aimport de.alpharogroup.file.delete.DeleteFileExtensions;%0Aimport de.alpharogroup.file.search.PathFinder;%0A%0A/**%0A * Test class for the class %7B@link KeyStoreFactory%7D.%0A */%0Apublic class KeyStoreFactoryTest %7B%0A%0A%09/**%0A%09 * Test method for%0A%09 * %7B@link KeyStoreFactory#newKeyStore(String, String, File, boolean)%7D. %0A%09 * %0A%09 * @throws NoSuchAlgorithmException%0A%09 *             if the algorithm used to check the integrity of the keystore%0A%09 *             cannot be found%0A%09 * @throws CertificateException%0A%09 *             if any of the certificates in the keystore could not be%0A%09 *             loaded%0A%09 * @throws FileNotFoundException%0A%09 *             if the file not found%0A%09 * @throws KeyStoreException%0A%09 *             if the keystore has not been initialized (loaded).%0A%09 * %0A%09 * @throws IOException%0A%09 *             Signals that an I/O exception has occurred.%0A%09 */%0A%09@Test%0A%09public void testNewKeyStore() throws NoSuchAlgorithmException, CertificateException, FileNotFoundException,%0A%09%09%09KeyStoreException, IOException %7B%0A%09%09final File publickeyDerDir = new File(PathFinder.getSrcTestResourcesDir(), %22der%22);%0A%09%09final File privatekeyDerFile = new File(publickeyDerDir, %22keystore.jks%22);%0A%0A%09%09KeyStore keystore = KeyStoreFactory.newKeyStore(%22jks%22, %22foobar-secret-pw%22, privatekeyDerFile, true);%0A%09%09AssertJUnit.assertNotNull(keystore);%0A%09%09DeleteFileExtensions.delete(privatekeyDerFile);%0A%09%7D%0A%0A%7D%0A

Create KeyStoreFactoryTest.java