Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

requirements.cli.requirements_review_skill.review_prompt.design

Requirements index · View definition

evidence Valid

Requirement

The review prompt MUST direct the reviewer to return the following as design questions, each with why it matters, the options, and a recommendation:

  • gaps where more than one answer is plausible;
  • conflicts with other requirements, citing them by full name;
  • MUST versus SHOULD where the choice depends on the user’s intent;
  • obligations nothing could check, where any fix changes what is promised.

Rationale

The subject requires the review prompt to direct the reviewer to return four kinds of design question. For each question it must give why it matters, the options, and a recommendation. The requirement is about prompt content, so a test that asserts the shipped prompt text is the right kind of check.

tests/authoring_cli.rs#fn[the_review_prompt_lists_the_design_questions_with_options_and_recommendation] extracts the prompt span from **Design questions:** to ## Finding gaps. It uses review_prompt_between, which reads references/review-prompt.md and collapses whitespace so wrapped lines match. It then uses assert_text to require that each of these phrases is present:

  • “A gap: a case the text says nothing about, where either answer is plausible” covers gaps with more than one plausible answer.
  • “A conflict with another requirement; cite it by full name” covers conflicts, including the citation by full name.
  • “MUST or SHOULD when the choice depends on the user’s intent” covers MUST versus SHOULD depending on intent.
  • “An obligation nothing could check, where any fix changes what is promised” covers obligations nothing could check.
  • “For each question give why it matters, the options, and your recommendation” covers all three attributes of each question.

I compared the phrases with the prompt source and they match its bullets and closing sentence. Scoping the check to the design-questions span means a phrase appearing elsewhere in the prompt cannot satisfy it.

The framing that these items are returned as design questions for the user to decide is asserted in the_review_prompt_makes_mechanical_changes_and_returns_design_questions (“Design questions: return these; the user decides”). That test is marked for the parent requirement. The “### Design questions” report heading is asserted in the_review_prompt_gives_a_report_template, marked for review_prompt.report. Neither is an obligation of this subject.

I found no obligation of the subject that goes untested.

Inputs

Tests

Input 2: outline tests/authoring_cli.rs fn[the_review_prompt_lists_the_design_questions_with_options_and_recommendation]
// {test}`requirements.cli.requirements_review_skill.review_prompt.design`
#[test]
fn the_review_prompt_lists_the_design_questions_with_options_and_recommendation() {
    assert_text(
        "design questions",
        &review_prompt_between("**Design questions:**", "## Finding gaps"),
        &[
            "A gap: a case the text says nothing about, where either answer is plausible",
            "A conflict with another requirement; cite it by full name",
            "MUST or SHOULD when the choice depends on the user's intent",
            "An obligation nothing could check, where any fix changes what is promised",
            "For each question give why it matters, the options, and your recommendation",
        ],
    );
}

Other sources

Input 1: requirements selection requirements.cli.requirements_review_skill.review_prompt.design
:::{req} requirements_review_skill.review_prompt.design
The review prompt MUST direct the reviewer to return the following as design questions, each with why it matters, the options, and a recommendation:

- gaps where more than one answer is plausible;
- conflicts with other requirements, citing them by full name;
- MUST versus SHOULD where the choice depends on the user's intent;
- obligations nothing could check, where any fix changes what is promised.
:::