Exercise 2: A SILVER Tier, Documented and Then Left Stale — Possible Solution ==================================================================== THE STATIC DOC AND POLICY CHANGE ------------------------------ STATIC_DOC_SILVER = "SILVER members receive a 5% discount at checkout." Before the change: apply_discount(100, "SILVER") = $95.00 -> matches the doc's own "5% discount" claim After changing SILVER from 5% to 8% off: apply_discount_with_silver_v2(100, "SILVER") = $92.00 Doc still says 5%: unchanged text, still reads exactly as before Mismatch confirmed: True WHY NOTHING CAUGHT IT ------------------------------ STATIC_DOC_SILVER is a plain string, syntactically valid before and after the change. Nothing about running apply_discount_with_silver_v2, compiling the file, or any test suite that doesn't specifically check the doc's own text against the function's own output has any way to notice the two have diverged. WHY THIS WORKS AS AN ANSWER ------------------------------ This reproduces the chapter's own core finding a second time with a freshly-introduced tier rather than the chapter's own pre-existing GOLD example, confirming the silent-decay problem isn't specific to one particular piece of documentation - it's a structural property of any description that isn't itself executed and checked. The fix is the same one the chapter already demonstrated: replacing this static sentence with a Given-When-Then scenario asserting on the real, current discount value would have failed loudly the moment the SILVER policy changed, instead of silently misinforming anyone who reads it afterward.