mirror of
https://github.com/pgpainless/pgpainless.git
synced 2025-09-13 20:29:39 +02:00
Introduce ImplementationFactory
This commit is contained in:
parent
c7ede0fc8a
commit
1c1f9d49ab
22 changed files with 655 additions and 91 deletions
|
@ -21,6 +21,7 @@ import static org.junit.jupiter.api.Assertions.assertNull;
|
|||
import javax.annotation.Nullable;
|
||||
|
||||
import org.bouncycastle.openpgp.PGPException;
|
||||
import org.bouncycastle.openpgp.PGPSecretKey;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.pgpainless.key.TestKeys;
|
||||
import org.pgpainless.key.protection.passphrase_provider.SecretKeyPassphraseProvider;
|
||||
|
@ -37,7 +38,7 @@ public class PassphraseProtectedKeyTest {
|
|||
@Nullable
|
||||
@Override
|
||||
public Passphrase getPassphraseFor(Long keyId) {
|
||||
if (keyId == TestKeys.CRYPTIE_KEY_ID) {
|
||||
if (keyId.equals(TestKeys.CRYPTIE_KEY_ID)) {
|
||||
return new Passphrase(TestKeys.CRYPTIE_PASSWORD.toCharArray());
|
||||
} else {
|
||||
return null;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue