-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adding support for audio items with no derivatives
- Loading branch information
1 parent
704649e
commit 2068f13
Showing
2 changed files
with
25 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
import os | ||
|
||
import unittest | ||
import math | ||
from flask.testing import FlaskClient | ||
from iiify.app import app | ||
|
||
class TestAudio(unittest.TestCase): | ||
|
||
def setUp(self) -> None: | ||
os.environ["FLASK_CACHE_DISABLE"] = "true" | ||
self.test_app = FlaskClient(app) | ||
|
||
def test_audio_no_derivatives(self): | ||
resp = self.test_app.get("/iiif/3/kaled_jalil/manifest.json") | ||
self.assertEqual(resp.status_code, 200) | ||
manifest = resp.json | ||
|
||
self.assertEqual(len(manifest['items']),114,f"Expected 114 canvases but got: {len(manifest['items'])}") |