~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/revision.py

  • Committer: Vincent Ladeuil
  • Date: 2009-05-05 15:31:34 UTC
  • mto: (4343.1.1 integration)
  • mto: This revision was merged to the branch mainline in revision 4344.
  • Revision ID: v.ladeuil+lp@free.fr-20090505153134-q4bp4is9gywsmzrv
Clean up test for log formats.

* bzrlib/tests/blackbox/test_logformats.py:
Update tests to actual style.

Show diffs side-by-side

added added

removed removed

Lines of Context:
68
68
    def __eq__(self, other):
69
69
        if not isinstance(other, Revision):
70
70
            return False
 
71
        # FIXME: rbc 20050930 parent_ids are not being compared
71
72
        return (
72
73
                self.inventory_sha1 == other.inventory_sha1
73
74
                and self.revision_id == other.revision_id
75
76
                and self.message == other.message
76
77
                and self.timezone == other.timezone
77
78
                and self.committer == other.committer
78
 
                and self.properties == other.properties
79
 
                and self.parent_ids == other.parent_ids)
 
79
                and self.properties == other.properties)
80
80
 
81
81
    def __ne__(self, other):
82
82
        return not self.__eq__(other)
111
111
 
112
112
    def get_summary(self):
113
113
        """Get the first line of the log message for this revision.
114
 
 
115
 
        Return an empty string if message is None.
116
114
        """
117
 
        if self.message:
118
 
            return self.message.lstrip().split('\n', 1)[0]
119
 
        else:
120
 
            return ''
 
115
        return self.message.lstrip().split('\n', 1)[0]
121
116
 
122
117
    @symbol_versioning.deprecated_method(symbol_versioning.deprecated_in((1, 13, 0)))
123
118
    def get_apparent_author(self):