~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/selftest/testgpg.py

  • Committer: Robert Collins
  • Date: 2005-10-17 11:56:54 UTC
  • mfrom: (1185.16.59)
  • Revision ID: robertc@robertcollins.net-20051017115654-662239e1587524a8
mergeĀ fromĀ martin.

Show diffs side-by-side

added added

removed removed

Lines of Context:
23
23
 
24
24
import bzrlib.errors as errors
25
25
import bzrlib.gpg as gpg
26
 
from bzrlib.tests import TestCase, TestCaseInTempDir
 
26
from bzrlib.selftest import TestCase, TestCaseInTempDir
27
27
 
28
28
class FakeConfig(object):
29
29
 
50
50
        my_gpg._command_line = lambda:["cat", "-"]
51
51
        self.assertEqual("some content\nwith newlines\n",
52
52
                         my_gpg.sign("some content\nwith newlines\n"))
53
 
 
54
 
 
55
 
class TestDisabled(TestCase):
56
 
 
57
 
    def test_sign(self):
58
 
        self.assertRaises(errors.SigningFailed,
59
 
                          gpg.DisabledGPGStrategy(None).sign, 'content')