~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to testbzr

  • Committer: Martin Pool
  • Date: 2005-05-11 02:30:01 UTC
  • Revision ID: mbp@sourcefrog.net-20050511023000-5580a38e987bb915
- tests for bzr root

Show diffs side-by-side

added added

removed removed

Lines of Context:
140
140
    
141
141
    runcmd(['mkdir', TESTDIR])
142
142
    cd(TESTDIR)
 
143
    test_root = os.getcwd()
143
144
 
144
145
    progress("introductory commands")
145
146
    runcmd("bzr version")
166
167
    cd('branch1')
167
168
    runcmd('bzr init')
168
169
 
 
170
    assert backtick('bzr root')[:-1] == os.path.join(test_root, 'branch1')
 
171
 
169
172
    progress("status of new file")
170
173
    
171
174
    f = file('test.txt', 'wt')
261
264
    runcmd(['bzr', 'commit', '-m', 'rename nested subdirectories'])
262
265
 
263
266
    cd('sub1/sub2')
 
267
    assert backtick('bzr root')[:-1] == os.path.join(test_root, 'branch1')
264
268
    runcmd('bzr move ../hello.txt .')
265
269
    assert exists('./hello.txt')
266
270
    assert backtick('bzr relpath hello.txt') == 'sub1/sub2/hello.txt\n'