~ubuntu-branches/debian/jessie/bzr-git/jessie

« back to all changes in this revision

Viewing changes to tests/test_branch.py

  • Committer: Package Import Robot
  • Author(s): Jelmer Vernooij
  • Date: 2011-11-09 21:04:04 UTC
  • mfrom: (1.1.24)
  • Revision ID: package-import@ubuntu.com-20111109210404-2f9fpac10pylw1bu
Tags: 0.6.5+bzr1465-1
* New upstream snapshot.
 + Fix compatibility with older pre-releases of bzr 2.5.

Show diffs side-by-side

added added

removed removed

Lines of Context:
121
121
        revb = r.do_commit("b", committer="Somebody <foo@example.com>")
122
122
 
123
123
        thebranch = Branch.open('.')
124
 
        if bzrlib_version >= (2, 5, 0):
125
 
            self.assertEqual([default_mapping.revision_id_foreign_to_bzr(r) for r in (reva, revb)],
126
 
                             self.applyDeprecated(deprecated_in((2, 5, 0)), thebranch.revision_history))
127
 
        else:
128
 
            self.assertEqual([default_mapping.revision_id_foreign_to_bzr(r) for r in (reva, revb)],
129
 
                thebranch.revision_history())
 
124
        (warnings, history) = self.callCatchWarnings(thebranch.revision_history)
 
125
        self.assertTrue(
 
126
            warnings == [] or 
 
127
            (len(warnings) == 1 and isinstance(warnings[0], DeprecationWarning)),
 
128
            warnings)
 
129
        self.assertEqual([default_mapping.revision_id_foreign_to_bzr(r) for r in (reva, revb)],
 
130
                         history)
130
131
 
131
132
    def test_tag_annotated(self):
132
133
        reva = self.simple_commit_a()