More tests.
[cdist.git] / cdist / tests / test_cmd_release.py
index 400e8af6c3647fb55f1990a75175b35e8f197bad..6d6bb525976739eea13f200a167ba9fe32e3bca2 100644 (file)
@@ -21,21 +21,21 @@ from unittest import TestCase
 
 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'
@@ -55,3 +55,4 @@ class TestCmdRelease(TestCase):
         command('git reset --hard')
         with open('wscript', 'r') as f:
             self.assertEquals(f.readline().strip(), "VERSION = '0.1.0devel'")
+        chdir('../../')