diff options
author | Dominik Schürmann <dominik@dominikschuermann.de> | 2014-08-13 19:49:11 +0200 |
---|---|---|
committer | Dominik Schürmann <dominik@dominikschuermann.de> | 2014-08-13 19:49:11 +0200 |
commit | a20e019d5ed24b88f7f81f37e6a0674d3f0d1430 (patch) | |
tree | c857285beaf36bfcc99975d6032bf3aa639a5ca1 /OpenKeychain-Test/src/test | |
parent | 32d63828c7b332c10514e1d37c5137fea34cacd4 (diff) | |
download | open-keychain-a20e019d5ed24b88f7f81f37e6a0674d3f0d1430.tar.gz open-keychain-a20e019d5ed24b88f7f81f37e6a0674d3f0d1430.tar.bz2 open-keychain-a20e019d5ed24b88f7f81f37e6a0674d3f0d1430.zip |
Fix tests
Diffstat (limited to 'OpenKeychain-Test/src/test')
-rw-r--r-- | OpenKeychain-Test/src/test/java/org/sufficientlysecure/keychain/pgp/PgpKeyOperationTest.java | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/OpenKeychain-Test/src/test/java/org/sufficientlysecure/keychain/pgp/PgpKeyOperationTest.java b/OpenKeychain-Test/src/test/java/org/sufficientlysecure/keychain/pgp/PgpKeyOperationTest.java index 0ced85dd7..8e7d395fd 100644 --- a/OpenKeychain-Test/src/test/java/org/sufficientlysecure/keychain/pgp/PgpKeyOperationTest.java +++ b/OpenKeychain-Test/src/test/java/org/sufficientlysecure/keychain/pgp/PgpKeyOperationTest.java @@ -300,7 +300,7 @@ public class PgpKeyOperationTest { long expiry = new Date().getTime() / 1000 + 159; int flags = KeyFlags.SIGN_DATA; int bits = 1024 + new Random().nextInt(8); - parcel.mAddSubKeys.add(new SubkeyAdd(algorithm.rsa, bits, flags, expiry)); + parcel.mAddSubKeys.add(new SubkeyAdd(PublicKeyAlgorithmTags.RSA_GENERAL, bits, flags, expiry)); UncachedKeyRing modified = applyModificationWithChecks(parcel, ring, onlyA, onlyB); @@ -341,7 +341,7 @@ public class PgpKeyOperationTest { { // bad keysize should fail parcel.reset(); parcel.mAddSubKeys.add(new SubkeyAdd( - algorithm.rsa, new Random().nextInt(512), KeyFlags.SIGN_DATA, null)); + PublicKeyAlgorithmTags.RSA_GENERAL, new Random().nextInt(512), KeyFlags.SIGN_DATA, null)); CanonicalizedSecretKeyRing secretRing = new CanonicalizedSecretKeyRing(ring.getEncoded(), false, 0); modified = op.modifySecretKeyRing(secretRing, parcel, passphrase).getRing(); @@ -351,7 +351,7 @@ public class PgpKeyOperationTest { { // a past expiry should fail parcel.reset(); - parcel.mAddSubKeys.add(new SubkeyAdd(algorithm.rsa, 1024, KeyFlags.SIGN_DATA, + parcel.mAddSubKeys.add(new SubkeyAdd(PublicKeyAlgorithmTags.RSA_GENERAL, 1024, KeyFlags.SIGN_DATA, new Date().getTime()/1000-10)); CanonicalizedSecretKeyRing secretRing = new CanonicalizedSecretKeyRing(ring.getEncoded(), false, 0); |