move key stripping into ChangeSubkey, support divert-to-card

This commit is contained in:
Vincent Breitmoser
2015-01-24 23:05:50 +01:00
parent 53955a8014
commit 0e0970c347
7 changed files with 59 additions and 42 deletions

View File

@@ -701,7 +701,7 @@ public class PgpKeyOperationTest {
public void testSubkeyStrip() throws Exception {
long keyId = KeyringTestingHelper.getSubkeyId(ring, 1);
parcel.mStripSubKeys.add(keyId);
parcel.mChangeSubKeys.add(new SubkeyChange(keyId, true, false));
applyModificationWithChecks(parcel, ring, onlyA, onlyB);
Assert.assertEquals("one extra packet in original", 1, onlyA.size());
@@ -727,7 +727,7 @@ public class PgpKeyOperationTest {
public void testMasterStrip() throws Exception {
long keyId = ring.getMasterKeyId();
parcel.mStripSubKeys.add(keyId);
parcel.mChangeSubKeys.add(new SubkeyChange(keyId, true, false));
applyModificationWithChecks(parcel, ring, onlyA, onlyB);
Assert.assertEquals("one extra packet in original", 1, onlyA.size());