From 0ad9b4428efd5a002ec7271216d4cfdbcf4e9e07 Mon Sep 17 00:00:00 2001 From: Dan Callaghan Date: May 20 2018 23:59:29 +0000 Subject: fix unit tests in RPM build PR#199 broke the tests inside the RPM build, because now we are calling create_app(), and it was unintentionally loading a production config instead of a testing config. The fix for that is really PR#192 but that was not taking effect because the conftest.py file in the root directory was not being included in the source tarballs. --- diff --git a/MANIFEST.in b/MANIFEST.in index 1edd420..f0c960b 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -1,6 +1,6 @@ global-exclude *.pyc *.pyo include COPYING README.md requirements.txt dev-requirements.txt -include pytest.ini +include pytest.ini conftest.py include run-dev-server.py include tox.ini include fedmsg.d/*.py diff --git a/greenwave.spec b/greenwave.spec index aa8cc41..0c1db63 100644 --- a/greenwave.spec +++ b/greenwave.spec @@ -73,7 +73,7 @@ DEV=true GREENWAVE_CONFIG=$(pwd)/conf/settings.py.example make -C docs SPHINXOPT %check export PYTHONPATH=%{buildroot}/%{python2_sitelib} -GREENWAVE_CONFIG=$(pwd)/conf/settings.py.example py.test greenwave/tests/ +py.test greenwave/tests/ %files %license COPYING