fix(school): send the school page its admissions policy, and read it exactly
The header's Selective flag read school_info.admissions_policy, which the detail endpoint never sent, so no school page could flag Selective while its search row did (staging E2E: The Grammar School at Leeds). The detail payload now carries it, and a contract test checks it carries every field the header's flags read. Sending it would have switched on two older copies of the tag logic #176 fixed in the rows. The Admissions section and the cut-off note both tested includes('selective'), so every non-selective secondary would have read "entry is by selective examination". The section also counted "None" as a faith: Burntwood reads "a faith-based admissions priority (None)" today. All of them now share isSelective() and hasReligiousCharacter(), which also treats "Not applicable" as no faith, as the place table already does. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
392ec29fdb
commit
ef4a2ccccb
9 files changed
+144
-13
No files matched your search
@@ -1047,6 +1047,8 @@ async def get_school_details(request: Request, urn: int):
|
||||
"age_range": latest.get("age_range", ""),
|
||||
"has_sixth_form": latest.get("has_sixth_form"),
|
||||
"nursery_provision": latest.get("nursery_provision"),
|
||||
# The header's Selective flag reads it (lib/schoolFacts).
|
||||
"admissions_policy": latest.get("admissions_policy"),
|
||||
"status": latest.get("status"),
|
||||
"latitude": latest.get("latitude"),
|
||||
"longitude": latest.get("longitude"),
|
||||
|
||||
Reference in new issue
Block a user