import cdist.cmd_release
import cdist.globals
-from cdist.util import command
+from cdist.util import command, chdir
import prepare
class TestCmdRelease(TestCase):
def test(self):
prepare.project()
- os.chdir('test/project.git')
+ chdir('test/project.git')
with open('wscript', 'w') as f:
print>>f,"VERSION = '0.0.1'"
command('git add wscript')
command('git commit -a -m "foo"')
# Allow pushing to a non-bare repo for this test
command('git config receive.denyCurrentBranch ignore')
- os.chdir('../..')
+ chdir('../..')
class Args:
target = 'test'
command('git reset --hard')
with open('wscript', 'r') as f:
self.assertEquals(f.readline().strip(), "VERSION = '0.1.0devel'")
+ chdir('../../')