@Test
void createKeystore_checkPropertiesFile() throws IOException {

    final KeystoreHelper keystoreHelper = new KeystoreHelper();
    KeystoreCreator.updateSystemPropertiesFile(keystoreHelper, keystoreFile, systemProperties.getPath());
    assertTrue(systemProperties.exists());
    try (InputStream stream = Files.newInputStream(systemProperties.toPath())){
        Properties properties = new Properties();
        properties.load(stream);
        assertFalse(properties.isEmpty());
        assertEquals(6, properties.size());
        assertNotNull(properties.getProperty("com.l7tech.common.security.jceProviderEngineName"));
        assertEquals("generic", properties.getProperty("com.l7tech.common.security.jceProviderEngineName"));
        assertNotNull(properties.getProperty("com.l7tech.keystore.type"));
        assertEquals(keystoreHelper.getKeyStoreType(), properties.getProperty("com.l7tech.keystore.type"));
        assertNotNull(properties.getProperty("com.l7tech.keystore.path"));
        assertEquals(FilenameUtils.separatorsToUnix(keystoreFile.getPath()), properties.getProperty("com.l7tech.keystore.path"));
        assertNotNull(properties.getProperty("com.l7tech.keystore.savePath"));
        assertEquals("EMPTY", properties.getProperty("com.l7tech.keystore.savePath"));
        assertNotNull(properties.getProperty("com.l7tech.keystore.password"));
        assertEquals(new String(keystoreHelper.getKeystorePassword()), properties.getProperty("com.l7tech.keystore.password"));
        assertNotNull(properties.getProperty("com.l7tech.common.security.jceProviderEngine"));
        assertEquals("com.l7tech.security.prov.generic.GenericJceProviderEngine", properties.getProperty("com.l7tech.common.security.jceProviderEngine"));
    }
    Files.delete(systemProperties.toPath());
}