At file:///home/vila/src/bzr/cleanup/deprecations/

------------------------------------------------------------
revno: 5347
revision-id: [email protected]
parent: [email protected]
committer: Vincent Ladeuil <[email protected]>
branch nick: deprecations
timestamp: Thu 2010-07-15 14:37:32 +0200
message:
  Delete Revision.get_apparent_author.
=== modified file 'bzrlib/revision.py'
--- a/bzrlib/revision.py        2010-02-23 07:43:11 +0000
+++ b/bzrlib/revision.py        2010-07-15 12:37:32 +0000
@@ -121,21 +121,6 @@
         else:
             return ''
 
-    @symbol_versioning.deprecated_method(symbol_versioning.deprecated_in((1, 
13, 0)))
-    def get_apparent_author(self):
-        """Return the apparent author of this revision.
-
-        This method is deprecated in favour of get_apparent_authors.
-
-        If the revision properties contain any author names,
-        return the first. Otherwise return the committer name.
-        """
-        authors = self.get_apparent_authors()
-        if authors:
-            return authors[0]
-        else:
-            return None
-
     def get_apparent_authors(self):
         """Return the apparent authors of this revision.
 

=== modified file 'bzrlib/tests/test_revision.py'
--- a/bzrlib/tests/test_revision.py     2009-06-03 10:24:28 +0000
+++ b/bzrlib/tests/test_revision.py     2010-07-15 12:37:32 +0000
@@ -211,31 +211,6 @@
         r.message = None
         self.assertEqual('', r.get_summary())
 
-    def test_get_apparent_author(self):
-        r = revision.Revision('1')
-        r.committer = 'A'
-        author = self.applyDeprecated(
-                symbol_versioning.deprecated_in((1, 13, 0)),
-                r.get_apparent_author)
-        self.assertEqual('A', author)
-        r.properties['author'] = 'B'
-        author = self.applyDeprecated(
-                symbol_versioning.deprecated_in((1, 13, 0)),
-                r.get_apparent_author)
-        self.assertEqual('B', author)
-        r.properties['authors'] = 'C\nD'
-        author = self.applyDeprecated(
-                symbol_versioning.deprecated_in((1, 13, 0)),
-                r.get_apparent_author)
-        self.assertEqual('C', author)
-
-    def test_get_apparent_author_none(self):
-        r = revision.Revision('1')
-        author = self.applyDeprecated(
-                symbol_versioning.deprecated_in((1, 13, 0)),
-                r.get_apparent_author)
-        self.assertEqual(None, author)
-
     def test_get_apparent_authors(self):
         r = revision.Revision('1')
         r.committer = 'A'

-- 
bazaar-commits mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/bazaar-commits

Reply via email to