]> git.rkrishnan.org Git - tahoe-lafs/tahoe-lafs.git/commitdiff
setup: when testing, set the __requires__ as precisely as possible even if the versio...
authorZooko O'Whielacronx <zooko@zooko.com>
Fri, 19 Nov 2010 07:40:43 +0000 (23:40 -0800)
committerZooko O'Whielacronx <zooko@zooko.com>
Fri, 19 Nov 2010 07:40:43 +0000 (23:40 -0800)
setup.py

index 0b35f73b98449e781c3d336ef5d0069c1feed2ca..027427a06a088fc96dca974aef8a864b879fdfae 100644 (file)
--- a/setup.py
+++ b/setup.py
@@ -63,8 +63,12 @@ adglobals = {}
 execfile('src/allmydata/_auto_deps.py', adglobals)
 install_requires = adglobals['install_requires']
 
-if ('trial' in sys.argv or 'test' in sys.argv) and version is not None:
-    __requires__ = [APPNAME + '==' + version] + install_requires
+__requires__ = install_requires[:]
+if 'trial' in sys.argv or 'test' in sys.argv:
+    if version is not None:
+        __requires__.append(APPNAME + '==' + version)
+    else:
+        __requires__.append(APPNAME)
 
 egg = os.path.realpath(glob.glob('setuptools-*.egg')[0])
 sys.path.insert(0, egg)