aboutsummaryrefslogtreecommitdiff
path: root/src/mailman_pgp/pgp/tests/test_pgp.py
diff options
context:
space:
mode:
Diffstat (limited to 'src/mailman_pgp/pgp/tests/test_pgp.py')
-rw-r--r--src/mailman_pgp/pgp/tests/test_pgp.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/mailman_pgp/pgp/tests/test_pgp.py b/src/mailman_pgp/pgp/tests/test_pgp.py
index ab2a69a..6ef531e 100644
--- a/src/mailman_pgp/pgp/tests/test_pgp.py
+++ b/src/mailman_pgp/pgp/tests/test_pgp.py
@@ -25,6 +25,7 @@ from mailman_pgp.config import config
from mailman_pgp.database import mm_transaction, transaction
from mailman_pgp.model.address import PGPAddress
from mailman_pgp.model.list import PGPMailingList
+from mailman_pgp.pgp.keygen import ListKeyGenerator
from mailman_pgp.testing.layers import PGPConfigLayer
from mailman_pgp.testing.pgp import load_key
@@ -37,7 +38,7 @@ class TestPGP(TestCase):
self.mlist = create_list('test@example.com',
style_name='pgp-default')
self.pgp_list = PGPMailingList.for_list(self.mlist)
- self.list_key = self.pgp_list.generate_key(True)
+ self.list_key = ListKeyGenerator(self.pgp_list).generate(True)
# Make Anne a member of this mailing list.
self.anne = subscribe(self.mlist, 'Anne', email='anne@example.org')
@@ -61,3 +62,7 @@ class TestPGP(TestCase):
with keyring.key(self.anne_key.fingerprint) as key:
self.assertTrue(key.is_public)
self.assertEqual(key.fingerprint, self.anne_key.fingerprint)
+
+ def test_archive_keydir(self):
+ keyring = config.pgp.archive_keyring
+ self.assertEqual(len(keyring), 0)