From a7d2d1d4827395bfba298fbf568f9a397c731761 Mon Sep 17 00:00:00 2001 From: Drake Stapleton Date: Sat, 31 Oct 2026 11:35:34 -0500 Subject: [PATCH] DRA-94: test ties zh-CN recheck count to data --- crates/site-builder/src/components/research_status.rs | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/crates/site-builder/src/components/research_status.rs b/crates/site-builder/src/components/research_status.rs index 32aa8d11..ef74c6f7 100644 --- a/crates/site-builder/src/components/research_status.rs +++ b/crates/site-builder/src/components/research_status.rs @@ -1108,6 +1108,15 @@ mod tests { assert!(parse(&count).is_err()); } + #[test] + fn zh_cn_independent_recheck_count_is_the_number_of_links() { + // The zh-CN page is hand-written, so tie its count to the data file. + let zh = include_str!("../../../../public/zh-CN/research/status/index.html"); + let r = &data().independent_rechecks; + let want = format!("独立复核:{}(截至 {})", r.links.len(), r.as_of); + assert!(zh.contains(&want), "zh-CN status page lacks `{want}`"); + } + /// The homepage lookup check, as a function so a mutated copy can be /// shown to fail it. fn check_homepage(d: &StatusData) -> Result<(), String> {