Fix tests after rebase
This commit is contained in:
parent
3297bbfcca
commit
5a5b6c27a4
2 changed files with 3 additions and 2 deletions
|
@ -145,6 +145,7 @@ def delete_key(keyhome, email):
|
||||||
if result[1]:
|
if result[1]:
|
||||||
# delete all keys matching this email address
|
# delete all keys matching this email address
|
||||||
p = subprocess.Popen(_build_command(keyhome, '--delete-key', '--batch', '--yes', result[1]), stdin=None, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
|
p = subprocess.Popen(_build_command(keyhome, '--delete-key', '--batch', '--yes', result[1]), stdin=None, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
|
||||||
|
p.communicate()
|
||||||
p.wait()
|
p.wait()
|
||||||
return True
|
return True
|
||||||
|
|
||||||
|
|
|
@ -12,14 +12,14 @@ class GnuPGUtilitiesTest(unittest.TestCase):
|
||||||
self.assertEqual(cmd, ["gpg", "--homedir", "test/keyhome", "--foo", "--bar"])
|
self.assertEqual(cmd, ["gpg", "--homedir", "test/keyhome", "--foo", "--bar"])
|
||||||
|
|
||||||
def test_key_confirmation_with_matching_email(self):
|
def test_key_confirmation_with_matching_email(self):
|
||||||
armored_key = self._load('test/keys/bob@disposlab')
|
armored_key = self._load('test/keys/bob@disposlab.pub')
|
||||||
matching_email = 'bob@disposlab'
|
matching_email = 'bob@disposlab'
|
||||||
|
|
||||||
is_confirmed = GnuPG.confirm_key(armored_key, matching_email)
|
is_confirmed = GnuPG.confirm_key(armored_key, matching_email)
|
||||||
self.assertTrue(is_confirmed)
|
self.assertTrue(is_confirmed)
|
||||||
|
|
||||||
def test_key_confirmation_email_mismatch(self):
|
def test_key_confirmation_email_mismatch(self):
|
||||||
armored_key = self._load('test/keys/bob@disposlab')
|
armored_key = self._load('test/keys/bob@disposlab.pub')
|
||||||
not_matching_email = 'lucy@disposlab'
|
not_matching_email = 'lucy@disposlab'
|
||||||
|
|
||||||
is_confirmed = GnuPG.confirm_key(armored_key, not_matching_email)
|
is_confirmed = GnuPG.confirm_key(armored_key, not_matching_email)
|
||||||
|
|
Loading…
Reference in a new issue