# Write a scenario with a checkable expectation ## Intention I want to keep the input, the question, and the expected answer as an executable scenario. The rule and the test are different inputs to the test runner. ## Incorrect form and why it stays silent A test without an expectation checks nothing. ```law title="Incorrect form" test "подача" { given { assert filed(); } evaluate truth(registered()); } ``` ## Correct form Minimal form for a scene: ```law language "law.core" version "0.2"; package recipes.n.r11 version "0.1.0"; namespace "urn:recipe:n-package:11"; relation filed(); relation registered(); rule Register strict { when filed(); then registered(); } ``` ## Frozen execution scene Two standalone scenes are kept here, one per file, so each scene has its own address. | Facts | Question | Answer | |---|---|---| | filed() | registered() | TRUE_ONLY, Register applied | | No filed() | registered() | NEITHER, Register not applied | ```law test "filing is recorded" { given { context { legal_time @2026-09-13; decision_time @2026-09-13T09:00:00+05:00; knowledge_time @2026-09-13T09:00:00+05:00; timezone "Asia/Almaty"; } assert filed(); } evaluate truth(registered()); expect truth_status == TRUE_ONLY; expect applied(Register); } ``` ```law test "silent rule without filing" { given { context { legal_time @2026-09-13; decision_time @2026-09-13T09:00:00+05:00; knowledge_time @2026-09-13T09:00:00+05:00; timezone "Asia/Almaty"; } } evaluate truth(registered()); expect truth_status == NEITHER; expect not applied(Register); } ``` ## Counterfactual `teaches` removes all expectations from the first test and checks LDC-E1316 at lower-test. The scene without a fact excludes a green test that accidentally got an answer from another input. ## Boundary The program is presented separately; given does not declare law. ## Pitfall A test without expect and a lost expectation must fail. Here the same defect is held by the mutation of the first test.