Skip to content

Commit 443bd7d

Browse files
committed
Updated runtime tests
1 parent c14c311 commit 443bd7d

File tree

1 file changed

+11
-2
lines changed

1 file changed

+11
-2
lines changed

runtime-tests/test_runtime.py

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,9 @@
99
As such, they may need to evolve with Macrostrat's data holdings.
1010
"""
1111

12-
from time import sleep
13-
1412
from pytest import mark
1513
from requests import Session
14+
from time import sleep
1615

1716
client = Session()
1817

@@ -55,3 +54,13 @@ def exponential_backoff(url):
5554
yield res
5655
sleep(2**i)
5756
yield res
57+
58+
59+
# Tile server should return an image for a legacy tile request
60+
def test_legacy_tile():
61+
# TODO: modify this for dev URLs
62+
url = "https://macrostrat.org/api/v2/maps/burwell/emphasized/1/0/1/tile.png"
63+
res = client.get(url)
64+
assert res.status_code == 200
65+
assert res.headers["Content-Type"] == "image/png"
66+
assert len(res.content) > 0, "Tile content should not be empty"

0 commit comments

Comments
 (0)