Skip to content

Commit

Permalink
Merge pull request #4185 from rlaverde/required-test-packages
Browse files Browse the repository at this point in the history
PR: Add testing requirements to setup.py
  • Loading branch information
ccordoba12 authored Mar 8, 2017
2 parents 61f64ef + bbc84e0 commit 8fa3cd4
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 14 deletions.
7 changes: 0 additions & 7 deletions continuous_integration/travis/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -62,13 +62,6 @@ install_pip()
{
# Install PyQt5
conda install 'pyqt>=5.6.0';

# Install testing packages
pip install pytest pytest-cov pytest-qt mock

# Install extra packages
EXTRA_PACKAGES="matplotlib pandas sympy pyzmq pillow"
pip install $EXTRA_PACKAGES
}


Expand Down
15 changes: 8 additions & 7 deletions continuous_integration/travis/run_test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,14 @@ set -ex
export TEST_CI_APP=True


# Extra packages to install besides Spyder regular dependencies
# We install them here and not in travis_install.sh to see if
# Spyder is correctly pulling its deps (some of them are shared
# with mpl)
export EXTRA_PACKAGES="nomkl pandas sympy pillow scipy"

# Install our builds of Spyder
if [ "$USE_CONDA" = true ] ; then
# Extra packages to install besides Spyder regular dependencies
# We install them here and not in travis_install.sh to see if
# Spyder is correctly pulling its deps (some of them are shared
# with mpl)
export EXTRA_PACKAGES="nomkl pandas sympy pillow scipy"

# Move to a tmp dir
mkdir ~/tmp
cd ~/tmp
Expand All @@ -25,7 +25,8 @@ if [ "$USE_CONDA" = true ] ; then
conda install -q $EXTRA_PACKAGES
else
cd $FULL_SPYDER_CLONE
pip install dist/spyder-*.whl
export WHEEL=`ls dist/spyder-*.whl`
pip install $WHEEL[test]
fi


Expand Down
15 changes: 15 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -289,8 +289,23 @@ def run(self):
'numpydoc',
]

extras_require = {
'test:python_version == "2.7"': ['mock'],
'test': ['pytest',
'pytest-qt',
'pytest-cov',
'mock',
'flaky',
'pandas',
'scipy',
'sympy',
'pillow',
'matplotlib'],
}

if 'setuptools' in sys.modules:
setup_args['install_requires'] = install_requires
setup_args['extras_require'] = extras_require

setup_args['entry_points'] = {
'gui_scripts': [
Expand Down

0 comments on commit 8fa3cd4

Please sign in to comment.