~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_log.py

  • Committer: Jelmer Vernooij
  • Date: 2012-02-18 16:55:04 UTC
  • mfrom: (6437.23.10 2.5)
  • mto: This revision was merged to the branch mainline in revision 6469.
  • Revision ID: jelmer@samba.org-20120218165504-c9oe5c5ue805y8wp
Merge bzr/2.5.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# Copyright (C) 2005-2010 Canonical Ltd
 
1
# Copyright (C) 2005-2011 Canonical Ltd
2
2
#
3
3
# This program is free software; you can redistribute it and/or modify
4
4
# it under the terms of the GNU General Public License as published by
24
24
    registry,
25
25
    revision,
26
26
    revisionspec,
27
 
    symbol_versioning,
28
27
    tests,
29
28
    )
30
29
 
251
250
        wt.commit(message='add file1 and file2')
252
251
        self.run_bzr('branch parent child')
253
252
        os.unlink('child/file1')
254
 
        file('child/file2', 'wb').write('hello\n')
 
253
        with file('child/file2', 'wb') as f: f.write('hello\n')
255
254
        self.run_bzr(['commit', '-m', 'remove file1 and modify file2',
256
255
            'child'])
257
256
        os.chdir('parent')
1570
1569
    def assertLogRevnos(self, expected_revnos, b, start, end,
1571
1570
                        exclude_common_ancestry, generate_merge_revisions=True):
1572
1571
        # FIXME: the layering in log makes it hard to test intermediate levels,
1573
 
        # I wish adding filters with their parameters were easier...
 
1572
        # I wish adding filters with their parameters was easier...
1574
1573
        # -- vila 20100413
1575
1574
        iter_revs = log._calc_view_revisions(
1576
1575
            b, start, end, direction='reverse',
1636
1635
        log.Logger(b, request).show(log_formatter)
1637
1636
        # should now only have 2 revisions:
1638
1637
        self.assertEquals(len(log_formatter.revisions), 2)
 
1638