Skip to content
Snippets Groups Projects
Commit 97ad69b8 authored by Simon Künzel's avatar Simon Künzel
Browse files

Fix announcement test

parent efe51f98
No related branches found
No related tags found
No related merge requests found
......@@ -58,8 +58,6 @@ The current site status can be retrieved with `GET /status`. It can be in three
* 'This may be used while the site is [read-only](#site-status).'
* `unavailable`: The site is unavailable and the only route you can call is `GET /status`
### Miscellaneous
---
#### `GET /status`
......@@ -110,6 +108,8 @@ Returns `200 OK` if the site is ready to answer requests, otherwise `503 SERVICE
---
### Miscellaneous
#### `GET /homepage`
This may be used while the site is [read-only](#site-status).
......
......@@ -4,24 +4,28 @@ from object_data import *
class SiteTest(ApiTest):
def test_announcements(self):
def test_status(self):
# TODO test live config
self.do_json_request(
"GET",
"/announcements",
"/status",
None,
{
"status": "available",
"announcements": [
TEST_DATA_ANNOUNCEMENT_1,
TEST_DATA_ANNOUNCEMENT_2
]
},
["announcements"]
ignore_array_order_keys=["announcements"],
ignore_value_keys=["is_debug"]
)
self.do_json_request(
"GET",
"/announcements",
"/status",
None,
{
"status": "available",
"announcements": [
TEST_DATA_ANNOUNCEMENT_1_MOD,
TEST_DATA_ANNOUNCEMENT_2_MOD,
......@@ -30,7 +34,8 @@ class SiteTest(ApiTest):
TEST_DATA_ANNOUNCEMENT_5_MOD
]
},
["announcements"],
ignore_array_order_keys=["announcements"],
ignore_value_keys=["is_debug"],
use_moderator_login=True
)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment