mirror of
https://github.com/ilri/dspace-statistics-api.git
synced 2025-07-05 05:53:29 +02:00
tests: Add tests for communities and collections
Also, separate tests for items, communities, and collections into their own files, leaving a single test for docs in its own file.
This commit is contained in:
18
tests/test_api_docs.py
Normal file
18
tests/test_api_docs.py
Normal file
@ -0,0 +1,18 @@
|
||||
from falcon import testing
|
||||
import pytest
|
||||
|
||||
from dspace_statistics_api.app import api
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
def client():
|
||||
return testing.TestClient(api)
|
||||
|
||||
|
||||
def test_get_docs(client):
|
||||
"""Test requesting the documentation at the root."""
|
||||
|
||||
response = client.simulate_get("/")
|
||||
|
||||
assert isinstance(response.content, bytes)
|
||||
assert response.status_code == 200
|
Reference in New Issue
Block a user