mirror of
https://github.com/ilri/dspace-statistics-api.git
synced 2025-05-08 14:16:01 +02:00
Changes for Falcon 3.0.0
Mostly it seems we just need to use resp.text instead of resp.body, including in falcon-swagger-ui (I forked the upstream one to make this change). See: https://falcon.readthedocs.io/en/latest/changes/3.0.0.html
This commit is contained in:
@ -6,12 +6,12 @@ from unittest.mock import patch
|
||||
import pytest
|
||||
from falcon import testing
|
||||
|
||||
from dspace_statistics_api.app import api
|
||||
from dspace_statistics_api.app import app
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
def client():
|
||||
return testing.TestClient(api)
|
||||
return testing.TestClient(app)
|
||||
|
||||
|
||||
def test_get_collection(client):
|
||||
|
@ -6,12 +6,12 @@ from unittest.mock import patch
|
||||
import pytest
|
||||
from falcon import testing
|
||||
|
||||
from dspace_statistics_api.app import api
|
||||
from dspace_statistics_api.app import app
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
def client():
|
||||
return testing.TestClient(api)
|
||||
return testing.TestClient(app)
|
||||
|
||||
|
||||
def test_get_community(client):
|
||||
|
@ -3,12 +3,12 @@
|
||||
import pytest
|
||||
from falcon import testing
|
||||
|
||||
from dspace_statistics_api.app import api
|
||||
from dspace_statistics_api.app import app
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
def client():
|
||||
return testing.TestClient(api)
|
||||
return testing.TestClient(app)
|
||||
|
||||
|
||||
def test_get_docs(client):
|
||||
|
@ -6,12 +6,12 @@ from unittest.mock import patch
|
||||
import pytest
|
||||
from falcon import testing
|
||||
|
||||
from dspace_statistics_api.app import api
|
||||
from dspace_statistics_api.app import app
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
def client():
|
||||
return testing.TestClient(api)
|
||||
return testing.TestClient(app)
|
||||
|
||||
|
||||
def test_get_item(client):
|
||||
|
Reference in New Issue
Block a user