/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_revision.py

  • Committer: Canonical.com Patch Queue Manager
  • Date: 2009-03-23 01:17:27 UTC
  • mfrom: (4165.3.2 ec2-ubuntu)
  • Revision ID: pqm@pqm.ubuntu.com-20090323011727-b4nl10tcxfo4jiwb
(robertc) Various tweaks to ec2 stuff,
        and make it less windows only. (Robert Collins)

Show diffs side-by-side

added added

removed removed

Lines of Context:
12
12
#
13
13
# You should have received a copy of the GNU General Public License
14
14
# along with this program; if not, write to the Free Software
15
 
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
 
15
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
16
16
 
17
17
 
18
18
import os
32
32
from bzrlib.deprecated_graph import Graph
33
33
from bzrlib.revision import (find_present_ancestors,
34
34
                             NULL_REVISION)
 
35
from bzrlib.symbol_versioning import one_three
35
36
from bzrlib.tests import TestCase, TestCaseWithTransport
36
37
from bzrlib.trace import mutter
37
38
from bzrlib.workingtree import WorkingTree
208
209
        self.assertEqual('a', r.get_summary())
209
210
        r.message = '\na\nb'
210
211
        self.assertEqual('a', r.get_summary())
211
 
        r.message = None
212
 
        self.assertEqual('', r.get_summary())
213
212
 
214
213
    def test_get_apparent_author(self):
215
214
        r = revision.Revision('1')
229
228
                r.get_apparent_author)
230
229
        self.assertEqual('C', author)
231
230
 
232
 
    def test_get_apparent_author_none(self):
233
 
        r = revision.Revision('1')
234
 
        author = self.applyDeprecated(
235
 
                symbol_versioning.deprecated_in((1, 13, 0)),
236
 
                r.get_apparent_author)
237
 
        self.assertEqual(None, author)
238
 
 
239
231
    def test_get_apparent_authors(self):
240
232
        r = revision.Revision('1')
241
233
        r.committer = 'A'
245
237
        r.properties['authors'] = 'C\nD'
246
238
        self.assertEqual(['C', 'D'], r.get_apparent_authors())
247
239
 
248
 
    def test_get_apparent_authors_no_committer(self):
249
 
        r = revision.Revision('1')
250
 
        self.assertEqual([], r.get_apparent_authors())
251
 
 
252
240
 
253
241
class TestRevisionBugs(TestCase):
254
242
    """Tests for getting the bugs that a revision is linked to."""