From e0987a9d04907efd923d26a969a53eb6b7fa5e98 Mon Sep 17 00:00:00 2001 From: Pierre-Yves Chibon Date: Dec 16 2019 09:03:55 +0000 Subject: [PATCH 1/3] Adjust change in the error message and support fedora-messaging 2.0.0 Signed-off-by: Pierre-Yves Chibon --- diff --git a/tests/conftest.py b/tests/conftest.py index 664720d..c7cfded 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -2,7 +2,6 @@ import os from copy import copy -from mock import patch import pytest from sqlalchemy import create_engine from waiverdb.app import create_app @@ -57,8 +56,7 @@ def client(app): by default. """ with app.test_client() as client: - with patch('fedora_messaging.api._session_cache'): - yield client + yield client @pytest.fixture() diff --git a/tests/test_api_v10.py b/tests/test_api_v10.py index 06b5d7f..e7957d2 100644 --- a/tests/test_api_v10.py +++ b/tests/test_api_v10.py @@ -260,7 +260,7 @@ def test_404_for_nonexistent_waiver(client, session): assert r.status_code == 404 res_data = json.loads(r.get_data(as_text=True)) message = ( - 'The requested URL was not found on the server. If you entered the ' + 'The requested URL was not found on the server. If you entered the ' 'URL manually please check your spelling and try again.') assert res_data['message'] == message From 53753be6b2dcd3abda88426ca396cb5546dabe3e Mon Sep 17 00:00:00 2001 From: Pierre-Yves Chibon Date: Dec 16 2019 09:03:55 +0000 Subject: [PATCH 2/3] Add missing requirement to the requirements.txt file Signed-off-by: Pierre-Yves Chibon --- diff --git a/requirements.txt b/requirements.txt index 3691d97..96b6b16 100644 --- a/requirements.txt +++ b/requirements.txt @@ -3,6 +3,7 @@ fedora_messaging Flask +Flask-Migrate Flask-RESTful!=0.3.6 Flask-SQLAlchemy flask-cors From 56d81cab9752e359e64f09b099a10f4a6fb1ff33 Mon Sep 17 00:00:00 2001 From: Pierre-Yves Chibon Date: Dec 16 2019 09:03:55 +0000 Subject: [PATCH 3/3] Add the test requirements when building the doc Signed-off-by: Pierre-Yves Chibon --- diff --git a/tox.ini b/tox.ini index ad7458a..102b81a 100644 --- a/tox.ini +++ b/tox.ini @@ -21,6 +21,7 @@ testpaths = tests/ changedir = docs deps = -rrequirements.txt + -rtest-requirements.txt whitelist_externals = mkdir rm