We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 9e72664 commit 39839f4Copy full SHA for 39839f4
tests.sh
@@ -1,13 +1,12 @@
1
#!/bin/bash
2
3
-PYTHON_VERSION=`python -c "import sys;t='{v[0]}.{v[1]}'.format(v=list(sys.version_info[:2]));sys.stdout.write(t)";`
+PYTHON_VERSION=`python -c "import platform; print(int(platform.python_version()[:1]))"`
4
+VERSION_THRESHOLD=3
5
6
echo "running tests on python $PYTHON_VERSION.x..."
7
-if [[ $PYTHON_VERSION == 3.* ]] ;
8
-then
9
- . run_tests_py3.sh
+if [[ ${PYTHON_VERSION} -ge ${VERSION_THRESHOLD} ]]; then
+ bash ./run_tests_py3.sh
10
else
11
- nosetests
12
-fi
13
-
+ nosetests
+fi
0 commit comments