ADD playgrounds and active visuals to tests
from utils import Session
-def test_visuals_public():
+def test_visuals_public_course():
student = Session("student")
# Get all course data with visuals enabled
@@ -21,4 +21,35 @@ def test_visuals_public():
)
# Just make sure it didn't 500
+ assert usage.headers['Content-Type'] == 'image/png'
+ assert usage.status_code == 200
+
+
+def test_visuals_public_playgrounds():
+ student = Session("student")
+
+ # Get the course visual
+ usage = student.get(
+ f"/public/visuals/usage/playgrounds",
+ return_request=True,
+ skip_verify=True,
+ )
+
+ # Just make sure it didn't 500
+ assert usage.headers['Content-Type'] == 'image/png'
+ assert usage.status_code == 200
+
+
+def test_visuals_public_active():
+ student = Session("student")
+
+ # Get the course visual
+ usage = student.get(
+ f"/public/visuals/usage/active",
+ return_request=True,
+ skip_verify=True,
+ )
+
+ # Just make sure it didn't 500
+ assert usage.headers['Content-Type'] == 'image/png'
assert usage.status_code == 200
