mirror of
https://github.com/pgpainless/pgpainless.git
synced 2025-09-10 10:49:39 +02:00
Basic v6 key generation test
This commit is contained in:
parent
f3cfcd9250
commit
6f3df4a51b
3 changed files with 44 additions and 24 deletions
|
@ -0,0 +1,18 @@
|
|||
package org.pgpainless.key.generation;
|
||||
|
||||
import org.bouncycastle.openpgp.PGPSecretKeyRing;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.pgpainless.PGPainless;
|
||||
import org.pgpainless.algorithm.OpenPGPKeyVersion;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
|
||||
public class GenerateV6KeyTest {
|
||||
|
||||
@Test
|
||||
public void generateModernV6Key() {
|
||||
PGPSecretKeyRing secretKey = PGPainless.generateKeyRing(OpenPGPKeyVersion.v6)
|
||||
.modernKeyRing("Alice <alice@example.org>");
|
||||
assertEquals(6, secretKey.getPublicKey().getVersion());
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue