summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorkennyballou <kballou@onyx.boisestate.edu>2013-04-02 17:56:51 -0600
committerkennyballou <kballou@onyx.boisestate.edu>2013-04-02 17:56:51 -0600
commit8c7c737fb408d479b468fffb21b6a4993849b5b6 (patch)
tree991fb148d5461cd6362f5b08662c46e06dd0cc8a
parent6fe27662b36ba78a6c9774235e04fa53ad6ec322 (diff)
downloadxnt-8c7c737fb408d479b468fffb21b6a4993849b5b6.tar.gz
xnt-8c7c737fb408d479b468fffb21b6a4993849b5b6.tar.xz
Add check for testing python2 explicitly
-rw-r--r--build.py12
1 files changed, 7 insertions, 5 deletions
diff --git a/build.py b/build.py
index b13c3d4..b30f43d 100644
--- a/build.py
+++ b/build.py
@@ -24,13 +24,15 @@ def build():
@xnt.target
def test():
"""Tests package"""
+ error_codes = []
print("Python Tests:")
- ec1 = xnt.setup(["test"])
+ error_codes.append(xnt.setup(["test"]))
clean()
- print("Python2 Tests:")
- ec2 = xnt.call(["python2", "setup.py", "test"])
- clean()
- return ec1 | ec2
+ if xnt.in_path("python2"):
+ print("Python2 Tests:")
+ error_codes.append(xnt.call(["python2", "setup.py", "test"]))
+ clean()
+ return sum(error_codes)
@xnt.target
def lint():