]> arthur.barton.de Git - bup.git/commitdiff
tgit.py: set BUP_MAIN_EXE and BUP_DIR in testpacks().
authorRob Browning <rlb@defaultvalue.org>
Sun, 14 Apr 2013 19:02:15 +0000 (14:02 -0500)
committerRob Browning <rlb@defaultvalue.org>
Sun, 14 Apr 2013 19:07:26 +0000 (14:07 -0500)
Set these variables in testpacks(), just as we do for
test_pack_name_lookup(), since it also depends on path.exe().

This was causing 'make check' to fail on Cygwin, and could be
reproduced on Linux by explicitly invoking tgit.py via "./wvtest.py
lib/bup/t/tgit.py".

Reported-by: Will Rouesnel <w.rouesnel@gmail.com>
Signed-off-by: Rob Browning <rlb@defaultvalue.org>
lib/bup/t/tgit.py

index b564736879756bff7c5e7cdabced646a7e23683a..1731c0fc95ae1fc7372d510b464ee7427be809b0 100644 (file)
@@ -50,8 +50,10 @@ def testencode():
 
 @wvtest
 def testpacks():
-    subprocess.call(['rm','-rf', 'pybuptest.tmp'])
-    git.init_repo('pybuptest.tmp')
+    os.environ['BUP_MAIN_EXE'] = bupmain = '../../../bup'
+    os.environ['BUP_DIR'] = bupdir = 'pybuptest.tmp'
+    subprocess.call(['rm','-rf', bupdir])
+    git.init_repo(bupdir)
     git.verbose = 1
 
     w = git.PackWriter()