~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/selftest/testworkingtree.py

  • Committer: Robert Collins
  • Date: 2005-10-18 06:42:17 UTC
  • mfrom: (0.2.1)
  • mto: This revision was merged to the branch mainline in revision 1463.
  • Revision ID: robertc@robertcollins.net-20051018064217-e810bd94c74a9ad1
Factor out the guts of 'pull' from the command into WorkingTree.pull().
(Robert Collins)

Show diffs side-by-side

added added

removed removed

Lines of Context:
93
93
        self.assertEqual('w', tree.branch._lock_mode)
94
94
        tree.unlock()
95
95
        self.assertEqual(None, tree.branch._lock_count)
 
96
        
 
97
    def test_pull(self):
 
98
        self.build_tree(['from/', 'from/file', 'to/'])
 
99
        br_a = Branch.initialize('from')
 
100
        br_a.add('file')
 
101
        br_a.commit('foo', rev_id='A')
 
102
        br_b = Branch.initialize('to')
 
103
        br_b.working_tree().pull(br_a)
 
104
        self.failUnless(br_b.has_revision('A'))
 
105
        self.assertEqual(['A'], br_b.revision_history())