test_licence_lines_are_dropped_from_a_real_header

Tests › tests/test_hash_file_docs.py

passed Passed in the packaged run.

What this test is for

Why it exists

The Perl header above carries BOTH — two prose lines and then copyright. The block is accepted for the prose and the licence lines are not published, because a reader searching the prose corpus for a concept should not match every file that shares a licence.

Given

  1. —
→

When

  1. doc = extract_file_doc("scripts/generate_errors.pl", PERL)
→

Then

  1. ✓ doc contains "Generate error.c"
  2. ✓ doc does not contain "SPDX"
  3. ✓ doc does not contain "Copyright"

tests/test_hash_file_docs.py:138 · its file's page

What it checks (3)

  1. assert "Generate error.c" in doc observes extract_file_doc via doc
  2. assert "SPDX" not in doc, doc observes extract_file_doc via doc
  3. assert "Copyright" not in doc, doc observes extract_file_doc via doc

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_licence_lines_are_dropped_from_a_real_header→extract_file_doc

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_licence_lines_are_dropped_from_a_real_header · 3 checksextract_file_docREQ-DDB-PIPE-008 · measured
Also reaches 1 requirement

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