### Question:
KeyStoreUtils { public static final KeyStore loadKeyStore(final String ksFilePath, final char[] ksPassword) throws KeyStoreException, NoSuchAlgorithmException, CertificateException, IOException { java.io.FileInputStream fis = null; try{ fis = new FileInputStream(new File(ksFilePath)); return loadKeyStore(fis, ksPassword) ; }finally{ if (fis != null) { fis.close(); } } }  static final KeyStore loadKeyStore(final String ksFilePath, final char[] ksPassword); static final KeyStore loadKeyStore(final byte[] keystoreFileContent, char[] ksPassword); static final byte[] loadKeystore(final String ksFilePath); static final void persistKeyStore(final KeyStore ks, final String ksFilePath, final char[] ksPassword); static final byte[] keyStoreToByteArray(final KeyStore ks, final char[] ksPassword);  }### Answer:
@Test public void testLoadKeyStoreIntoByteArray() { try{ byte[] keystoreFileContent = KeyStoreUtils.loadKeystore(ksFullyqualifiedPath) ; final KeyStore convertedKeystore = KeyStoreUtils.loadKeyStore(keystoreFileContent, KEYSTORE_PASSWORD) ; compareKeystores(this.keystore, convertedKeystore, "Byte[] converted keytstore is not the same as standardly loaded one" ) ; }catch(Throwable t) { throw new RuntimeException(t) ; } }