/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_transport_implementations.py

  • Committer: Martin Pool
  • Date: 2007-11-22 09:49:39 UTC
  • mto: This revision was merged to the branch mainline in revision 3017.
  • Revision ID: mbp@sourcefrog.net-20071122094939-7exa28yk7u0d40ch
Followon from MemoryTransport._abspath fix: add test_rename_across_subdirs, and fix error construction

Show diffs side-by-side

added added

removed removed

Lines of Context:
900
900
        self.assertFalse(t.has('adir/bdir'))
901
901
        self.assertFalse(t.has('adir/bsubdir'))
902
902
 
 
903
    def test_rename_across_subdirs(self):
 
904
        t = self.get_transport()
 
905
        if t.is_readonly():
 
906
            raise TestNotApplicable("transport is readonly")
 
907
        t.mkdir('a')
 
908
        t.mkdir('b')
 
909
        ta = t.clone('a')
 
910
        tb = t.clone('b')
 
911
        ta.put_bytes('f', 'aoeu')
 
912
        ta.rename('f', '../b/f')
 
913
        self.assertTrue(tb.has('f'))
 
914
        self.assertFalse(ta.has('f'))
 
915
        self.assertTrue(t.has('b/f'))
 
916
 
903
917
    def test_delete_tree(self):
904
918
        t = self.get_transport()
905
919