[ca-certificates-java] 40/46: Unit test for UpdateCertificates.processChanges()
Emmanuel Bourg
ebourg-guest at moszumanska.debian.org
Mon Feb 2 21:25:32 UTC 2015
This is an automated email from the git hooks/post-receive script.
ebourg-guest pushed a commit to branch master
in repository ca-certificates-java.
commit d98113f6b1bfaa948dcf27b494298af62c423994
Author: Emmanuel Bourg <ebourg at apache.org>
Date: Mon Mar 24 12:48:21 2014 +0000
Unit test for UpdateCertificates.processChanges()
---
src/test/java/org/debian/security/UpdateCertificatesTest.java | 11 +++++++++++
1 file changed, 11 insertions(+)
diff --git a/src/test/java/org/debian/security/UpdateCertificatesTest.java b/src/test/java/org/debian/security/UpdateCertificatesTest.java
index ea68239..d0d1094 100644
--- a/src/test/java/org/debian/security/UpdateCertificatesTest.java
+++ b/src/test/java/org/debian/security/UpdateCertificatesTest.java
@@ -19,6 +19,7 @@
package org.debian.security;
import java.io.File;
+import java.io.StringReader;
import org.junit.Before;
import org.junit.Test;
@@ -136,4 +137,14 @@ public class UpdateCertificatesTest {
keystore.load();
assertEquals(false, keystore.contains(ALIAS_CACERT));
}
+
+ @Test
+ public void testProcessChanges() throws Exception {
+ UpdateCertificates uc = new UpdateCertificates(ksFilename, ksPassword);
+ uc.processChanges(new StringReader(ADD_CACERT + "\n" + INVALID_CACERT + "\n" + REMOVE_CACERT + "\n"));
+ uc.finish();
+
+ KeyStoreHandler keystore = new KeyStoreHandler(ksFilename, ksPassword.toCharArray());
+ assertEquals(false, keystore.contains(ALIAS_CACERT));
+ }
}
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-java/ca-certificates-java.git
More information about the pkg-java-commits
mailing list