test_check_notes_name_each_requirement_in_no_pattern

Tests › tests/test_wiki_ears.py

passed Passed in the packaged run.

What this test is for

Why it exists

Notes come from the index's requirements table, full statement included.

Given

  1. db = tmp_path / "clew.db"
  2. conn = sqlite3.connect(db)
4 more
  1. conn.execute("CREATE TABLE requirements (id TEXT, acceptance TEXT, title TEXT)")
  2. conn.executemany( "INSERT INTO requirements VALUES (?, ?, ?)", [("REQ-A-1", "The loader shall parse once.", "Load"), ("REQ-B-1", "", "Load the data")], )
  3. conn.commit()
  4. conn.close()
→

When

  1. ears_notes(db, True)
  2. ears_notes(db, False)
→

Then

  1. ✓ ears_notes(db, True) equals ["note: REQ-B-1 is in no EARS pattern: 'Load the data'"]
  2. ✓ ears_notes(db, False) equals []

tests/test_wiki_ears.py:71 · its file's page

What it checks (2)

  1. assert ears_notes(db, True) == ["note: REQ-B-1 is in no EARS pattern: 'Load the data'"] observes ears_notes
  2. assert ears_notes(db, False) == [] observes ears_notes

Where the product reaches it

No product flow reaches this code: no product entry point's flow calls any of the functions this test calls.

Call flow

test_check_notes_name_each_requirement_in_no_pattern→ears_notes

What it reaches

Each row runs from this test, through the calls it makes, to the code a requirement names. If that code breaks, the test's checks are what should catch it. Reaching is not proving: a check only proves what it observes. No mutation records were given, so these rows say what the test REACHES.

test_check_notes_name_each_requirement_in_no_pattern · 2 checksears_notesconnectREQ-DDB-QUERY-001 · measuredears_notesREQ-DDB-WIKI-042 · measured
Also reaches 2 requirements

Its run touches their code; that is reach, not proof.