Back to index

obnam  1.1
Public Member Functions
obnamlib.encryption_tests.PublicKeyEncryptionTests Class Reference

List of all members.

Public Member Functions

def test_roundtrip_works

Detailed Description

Definition at line 175 of file encryption_tests.py.


Member Function Documentation

Definition at line 177 of file encryption_tests.py.

00177 
00178     def test_roundtrip_works(self):
00179         cleartext = 'hello, world'
00180         passphrase = 'password1'
00181         keyring = obnamlib.Keyring(cat('test-gpghome/pubring.gpg'))
00182         seckeys = obnamlib.SecretKeyring(cat('test-gpghome/secring.gpg'))
00183         
00184         encrypted = obnamlib.encrypt_with_keyring(cleartext, keyring)
00185         decrypted = obnamlib.decrypt_with_secret_keys(encrypted,
00186                                                       gpghome='test-gpghome')
00187     
00188         self.assertEqual(decrypted, cleartext)
00189 

Here is the call graph for this function:


The documentation for this class was generated from the following file: