1
from bzrlib.selftest.blackbox import ExternalBase
2
from unittest import makeSuite
4
class TestBzrTools(ExternalBase):
7
file(filename, 'wb').write('')
9
def test_clean_tree(self):
13
assert os.path.lexists('name~')
14
self.touch('name.pyc')
15
self.runbzr('clean-tree')
16
assert os.path.lexists('name~')
17
assert not os.path.lexists('name')
18
self.runbzr('clean-tree --detrius')
19
assert not os.path.lexists('name~')
20
assert os.path.lexists('name.pyc')
21
self.runbzr('clean-tree --ignored')
22
assert not os.path.lexists('name.pyc')
24
def test_shelve(self):
26
self.runbzr('commit -m uc --unchanged')
27
self.runbzr('shelve -r 1 -m foo', retcode=1)
30
return makeSuite(TestBzrTools)