~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/selftest/testannotate.py

  • Committer: Robert Collins
  • Date: 2005-10-17 21:20:18 UTC
  • mfrom: (1461)
  • mto: This revision was merged to the branch mainline in revision 1462.
  • Revision ID: robertc@robertcollins.net-20051017212018-5e2a78c67f36a026
merge from integration

Show diffs side-by-side

added added

removed removed

Lines of Context:
39
39
 
40
40
 
41
41
class TestAnnotate(TestCaseInTempDir):
 
42
    def setUp(self):
 
43
        super(TestAnnotate, self).setUp()
 
44
        b = Branch.initialize('.')
 
45
        self.build_tree_contents([('hello.txt', 'my helicopter\n')])
 
46
        b.add(['hello.txt'])
 
47
        b.commit('add hello', 
 
48
                 committer='test@user')
 
49
 
42
50
    def test_help_annotate(self):
43
51
        """Annotate command exists"""
44
52
        out, err = self.run_bzr_captured(['--no-plugins', 'annotate', '--help'])
 
53
 
 
54
    def test_annotate_cmd(self):
 
55
        out, err = self.run_bzr_captured(['annotate', 'hello.txt'])
 
56
        self.assertEquals(err, '')
 
57
        self.assertEqualDiff(out, '''\
 
58
    1 test@us | my helicopter
 
59
''')