From bf9a708e84646e51151d315a48aa33b5b9b0c69e Mon Sep 17 00:00:00 2001 From: Vincent Breitmoser Date: Tue, 23 Sep 2014 16:16:16 +0200 Subject: fix test case for new PassphraeCacheInterface --- .../keychain/pgp/PgpEncryptDecryptTest.java | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) (limited to 'OpenKeychain-Test/src') diff --git a/OpenKeychain-Test/src/test/java/org/sufficientlysecure/keychain/pgp/PgpEncryptDecryptTest.java b/OpenKeychain-Test/src/test/java/org/sufficientlysecure/keychain/pgp/PgpEncryptDecryptTest.java index cc2eda3bc..d6865f8ea 100644 --- a/OpenKeychain-Test/src/test/java/org/sufficientlysecure/keychain/pgp/PgpEncryptDecryptTest.java +++ b/OpenKeychain-Test/src/test/java/org/sufficientlysecure/keychain/pgp/PgpEncryptDecryptTest.java @@ -264,10 +264,19 @@ public class PgpEncryptDecryptTest { } @Override - public String getCachedPassphrase(long masterKeyId) throws NoSecretKeyException { + public String getCachedPassphrase(long masterKeyId, long subKeyId) throws NoSecretKeyException { if (mExpectedId != null){ Assert.assertEquals("requested passphrase must be for expected id", - (long) mExpectedId, masterKeyId); + (long) mExpectedId, subKeyId); + } + return mPassphrase; + } + + @Override + public String getCachedPassphrase(long subKeyId) throws NoSecretKeyException { + if (mExpectedId != null){ + Assert.assertEquals("requested passphrase must be for expected id", + (long) mExpectedId, subKeyId); } return mPassphrase; } -- cgit v1.2.3