Commit 3f2ec123 authored by MinchinWeb's avatar MinchinWeb

Convert test command to `green`

parent e143dca2
......@@ -14,10 +14,13 @@ matrix:
- python: "pypy"
- python: "pypy3"
install:
- "python -m pip install pip --upgrade"
- "pip install ."
- "pip install icalendar"
- "pip install pylint"
script: "./run-tests.sh"
- "pip install .[ical]"
- "pip install .[test]"
script:
- "green -vvr"
- "python -m pylint --errors-only topydo test"
# Cache Dependencies
cache:
directories:
......
......@@ -22,7 +22,7 @@ smoothly into topydo.
* Run tests with:
./run-tests.sh [python2|python3]
green
Obviously, I won't accept anything that makes the tests fail. When you submit
a Pull Request, Travis CI will automatically run all tests for various Python
......
#!/bin/bash
if [ "$1" = "python2" ] || [ "$1" = "python3" ]; then
PYTHON=$1
else
# run whatever is active
PYTHON=python
fi
# Run normal tests
if ! $PYTHON setup.py test; then
exit 1
fi
# pylint is not supported on 3.2, so skip the test there
if $PYTHON --version 2>&1 | grep 'Python 3\.2' > /dev/null; then
exit 0
fi
if ! $PYTHON -m pylint --errors-only topydo test; then
exit 1
fi
exit 0
......@@ -38,6 +38,8 @@ setup(
'ical': ['icalendar'],
'prompt-toolkit': ['prompt-toolkit >= 0.53'],
'edit-cmd-tests': ['mock'],
'test': ['green', 'coverage'],
'test:python_version!="3.2"': ['pylint'],
},
entry_points= {
'console_scripts': ['topydo = topydo.cli.UILoader:main'],
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment