12 lines
653 B
Python
12 lines
653 B
Python
# retoor <retoor@molodetz.nl>
|
|||
|
|
|
||
|
|
|
||
|
|
def test_seeded_posts_and_placeholders(anon):
|
||
|
|
rol = anon.get("/rol", headers={"Accept": "application/json"}).json()["posts"]
|
||
|
|
seeds = {"Een zes is geen ambitie.", "Af is een eigenschap.", "De assistent is geen senior.", "Geen cursus."}
|
||
|
|
assert seeds <= {post["title"] for post in rol}
|
||
|
|
assert all(post["is_placeholder"] for post in rol if post["title"] in seeds)
|
||
|
|
standaard = anon.get("/standaard", headers={"Accept": "application/json"}).json()["posts"]
|
||
|
|
keuzes = next(post for post in standaard if post["title"] == "Eenendertig keuzes. Jij hebt er nul.")
|
||
|
|
assert keuzes["is_placeholder"] is False
|