/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 breezy/tests/test_commit.py

  • Committer: Jelmer Vernooij
  • Date: 2018-03-25 11:39:36 UTC
  • mfrom: (6927 work)
  • mto: This revision was merged to the branch mainline in revision 6928.
  • Revision ID: jelmer@jelmer.uk-20180325113936-hmozv6e2ebvz6jdd
merge trunk

Show diffs side-by-side

added added

removed removed

Lines of Context:
331
331
            wt.unlock()
332
332
 
333
333
        inv = b.repository.get_inventory(r4)
334
 
        eq(inv[b'hello-id'].revision, r4)
335
 
        eq(inv[b'a-id'].revision, r1)
336
 
        eq(inv[b'b-id'].revision, r3)
 
334
        eq(inv.get_entry(b'hello-id').revision, r4)
 
335
        eq(inv.get_entry(b'a-id').revision, r1)
 
336
        eq(inv.get_entry(b'b-id').revision, r3)
337
337
 
338
338
    def test_removed_commit(self):
339
339
        """Commit with a removed file"""
373
373
              ['dirid', 'file1id', 'file2id'])
374
374
        wt.commit('dir/file1', specific_files=['dir/file1'], rev_id=b'1')
375
375
        inv = b.repository.get_inventory('1')
376
 
        self.assertEqual('1', inv['dirid'].revision)
377
 
        self.assertEqual('1', inv['file1id'].revision)
 
376
        self.assertEqual('1', inv.get_entry('dirid').revision)
 
377
        self.assertEqual('1', inv.get_entry('file1id').revision)
378
378
        # FIXME: This should raise a KeyError I think, rbc20051006
379
 
        self.assertRaises(BzrError, inv.__getitem__, 'file2id')
 
379
        self.assertRaises(BzrError, inv.get_entry, 'file2id')
380
380
 
381
381
    def test_strict_commit(self):
382
382
        """Try and commit with unknown files and strict = True, should fail."""