~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/per_versionedfile.py

  • Committer: Canonical.com Patch Queue Manager
  • Date: 2011-04-18 04:55:00 UTC
  • mfrom: (5784.2.1 754188-apport-test)
  • Revision ID: pqm@pqm.ubuntu.com-20110418045500-ce6lkgyiq7f47q43
(mbp) Rewrite test_report_bug_legacy away from using doctest (see bug
 764188) (Martin Pool)

Show diffs side-by-side

added added

removed removed

Lines of Context:
1482
1482
        else:
1483
1483
            return ('FileA',) + (suffix,)
1484
1484
 
1485
 
    def test_add_fallback_implies_without_fallbacks(self):
1486
 
        f = self.get_versionedfiles('files')
1487
 
        if getattr(f, 'add_fallback_versioned_files', None) is None:
1488
 
            raise TestNotApplicable("%s doesn't support fallbacks"
1489
 
                                    % (f.__class__.__name__,))
1490
 
        g = self.get_versionedfiles('fallback')
1491
 
        key_a = self.get_simple_key('a')
1492
 
        g.add_lines(key_a, [], ['\n'])
1493
 
        f.add_fallback_versioned_files(g)
1494
 
        self.assertTrue(key_a in f.get_parent_map([key_a]))
1495
 
        self.assertFalse(key_a in f.without_fallbacks().get_parent_map([key_a]))
1496
 
 
1497
1485
    def test_add_lines(self):
1498
1486
        f = self.get_versionedfiles()
1499
1487
        key0 = self.get_simple_key('r0')