~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/selftest/testlog.py

  • Committer: Martin Pool
  • Date: 2005-10-04 02:27:27 UTC
  • mfrom: (1399)
  • mto: (1185.13.3)
  • mto: This revision was merged to the branch mainline in revision 1400.
  • Revision ID: mbp@sourcefrog.net-20051004022727-aee7064c62e039a7
[merge] merge robertc's format5 integration

 - test status on specific files
 - track x bit
 - baz2bzr fixes
 - remotebranch fixes

Show diffs side-by-side

added added

removed removed

Lines of Context:
65
65
            self.assertEquals(expected, got)
66
66
 
67
67
    def test_cur_revno(self):
 
68
        b = Branch('.', init=True)
 
69
 
 
70
        lf = LogCatcher()
 
71
        b.commit('empty commit')
 
72
        show_log(b, lf, verbose=True, start_revision=1, end_revision=1)
 
73
        self.assertRaises(InvalidRevisionNumber, show_log, b, lf,
 
74
                          start_revision=2, end_revision=1) 
 
75
        self.assertRaises(InvalidRevisionNumber, show_log, b, lf,
 
76
                          start_revision=1, end_revision=2) 
 
77
        self.assertRaises(InvalidRevisionNumber, show_log, b, lf,
 
78
                          start_revision=0, end_revision=2) 
 
79
        self.assertRaises(InvalidRevisionNumber, show_log, b, lf,
 
80
                          start_revision=1, end_revision=0) 
 
81
        self.assertRaises(InvalidRevisionNumber, show_log, b, lf,
 
82
                          start_revision=-1, end_revision=1) 
 
83
        self.assertRaises(InvalidRevisionNumber, show_log, b, lf,
 
84
                          start_revision=1, end_revision=-1) 
 
85
 
 
86
    def test_cur_revno(self):
68
87
        b = Branch.initialize('.')
69
88
 
70
89
        lf = LogCatcher()