TOPIC 24/5112 MINNOT STARTED

Branch coverage

Every if in the code has two ways out. Branch coverage counts how many of those ways your tests took. It is a stricter goal than statement coverage.

L1–L4 are part of the Pro pass

L0 Explain simply

Analogy: a walk with forks in the path. You walk a trail and want to see all of it. If you stay on the main path, you pass every sign. But at each fork there is a side path you did not take. To say you have walked the whole trail, you must take both sides of every fork.

Daily List is a to-do list app. Leo, the developer, has written code that sets a reminder. Code is a list of steps, and some steps are forks. A fork is a decision, such as 'if the plan is free'. This plan check has two ways out, true and false. The result of one decision is a , and the path that follows it is a branch.

is the share of branches that tests have taken at least once. Tom, the tester, counts the links and asks which ones his tests have not used. Last lesson he counted steps. Now he counts the links between steps, including straight links and ways out of forks.

The picture has a limit. On a trail you can see a side path. In code, a way out may have no steps in it, so a count of steps cannot see it.

(SYNTHETIC / TRAINING ONLY: Daily List and every person named in this lesson are invented.)

PICTURE IT

The picture is the one the lesson above opens with. The table below shows how each part of it matches the software.

THE REAL JOB Count every link in the code flow graph, both straight links and decision outcomes, to find transfers no test has taken.

  1. Read the whole flow graph
  2. List all its branches
  3. Mark distinct branches taken
  4. Test and check the missing ones
Four steps for a branch count

HOW THE PICTURE MAPS

How each part of the picture matches the software
In the pictureIn the software
The trailThe code
A fork in the pathA decision
Each side of the forkA branch, one decision outcome
A side path with no signsA branch with no steps in it
Walking every link, including both sides of each forkFull branch coverage
A link with no forkAn unconditional transfer, still a branch

WHERE THIS PICTURE STOPS

  • On a trail you can see a side path. In code, a way out may hold no steps, so you must read the decision to find it.
  • A walker chooses a side. A test chooses a way out by the input it uses.
  • A trail has few forks. Code can have very many, and a tool must count them.

HOOK

Every link, not just each step.

REMEMBER IT THIS WAY

A contrast: two neighbours told apart by one test.

counts steps. counts all graph links: straight links, ways out of a fork, and side paths with no steps.

What each part of the trick stands for
In the trickWhat it stands for
Stepsstatements that ran
Ways outconditional transfers after a decision; straight transfers count too
Side patha branch with no steps in it

TELL A FRIEND

Walking past every sign may miss a side path. Count every link, including links with no fork.

OFTEN MIXED UP WITH Statement coverage. counts steps that ran. counts graph links, including straight transfers and decision outcomes.

PRACTISE AND KEEP

Sources for this topic — 3 sources
  1. Market practice

    ISTQB Certified Tester Foundation Level Syllabus v4.0.1 ↗ — International Software Testing Qualifications Board · Foundation v4.0.1, section 4.3.2, printed p.43: branches include unconditional and conditional transfers between graph nodes. Full primary PDF read 2026-10-24. Graphs and figures are synthetic.

    The examinable statement of what a foundation-level tester is expected to know: six chapters, 64 learning objectives, each tagged K1 Remember, K2 Understand or K3 Apply, plus the test-design techniques the qualification names and groups as black-box, white-box and experience-based.

    Used here for the test-craft questions a Payment Quality Assurance Analyst and a Production Support Analyst are asked. It is cited for what the syllabus says a tester must be able to do, never as a rule about how payments work. · Checked 2026-11-07

    v4.0.1 is dated 15 September 2024 and is a list of corrections to v4.0 (21 April 2023) that reworded six learning objectives — not a cosmetic reissue. 78 pages.

    Two traps this entry exists to stop. v4.0.2 is the German edition (1 March 2025, 94 pages), so sorting by version number reaches the wrong document. And the widely-repeated per-chapter question allocation "8 / 5 / 4 / 11 / 9 / 3" is wrong: it is 8 / 6 / 4 / 11 / 9 / 2, derived from three official sample-exam answer keys and confirmed against the Exam Structure Tables.

    The single most consequential detail for a question bank: white-box coverage — statement and branch — is K2 "Explain", not K3 "Apply" (FL-4.3.1, FL-4.3.2, FL-4.3.3), and MC/DC, path and condition coverage are declared out of scope in §4.3. A question asking a candidate to compute branch coverage is testing something this syllabus does not.

    Read through a mirror, because the publisher's own domain could not be fetched (a reachability gap, not a statement about the publisher). A 403 there is a policy refusal and says nothing about whether the document exists or is reachable elsewhere.

    Anyone on an unrestricted network should open the canonical URL above and confirm the section and page numbers cited against it. Every claim drawn from this entry is written so that it can be checked against a numbered page.

    Read from two independent PDF-to-markdown conversions mirrored on raw.githubusercontent.com. They are treated as faithful because they were produced by unrelated parties with different tooling, agree on the full 64-item objective set including wording, and reproduce the same internal inconsistency present in the source PDF. Chapter 1 reads "testware that supports" where Appendix B reads "that support". A conversion artefact does not replicate across two toolchains.

    The licence permits attributed non-commercial extracts and use as the basis for articles. Whether a site that sells a pass may rely on that is an owner's decision, not this entry's.

    7 November 2026 review: actual publisher PDF 4.0.1, 15 September 2024, 78 pages, front matter/copyright and relevant numbered operative sections 0.5–0.10 and chapters 1–6 compared with CTFLpractice lessons. Earlier mirror/search descriptions are historical access records. TheK2 white-box objectives require explanation; the source does not justify a categorical ban on small numeric illustrations that support explanation. Later Exam Rules 1.2§4.1.4 usesK2 for keyword definitions, while syllabus§0.5 usesK1; keep dated scopes distinct. No copied questions or figure assets.

  2. Market practice

    Glossary of testing terms from the International Software Testing Qualifications Board (equivalence partition, equivalence partitioning, boundary value) ↗ — International Software Testing Qualifications Board (ISTQB) · Glossary of testing terms: branch and branch coverage (general knowledge, page not opened)

    The board's glossary of testing terms. Cited for two definitions. An equivalence partition is a subset of a value domain for which a component or system is expected to treat all values the same. A boundary value is the minimum or maximum value of an ordered equivalence partition. · Checked 2026-10-12

    Seen as a search excerpt; the page was not opened. The authoring container could not resolve this publisher's host name when a fetch was tried on 12 October 2026 for related hosts, so this is a reachability gap and not a statement about the publisher. The glossary has an older and a newer version of the entry for equivalence partitioning; the newer one defines the partition rather than the technique.

  3. Market practice

    ISTQB CTFL syllabus v 4.0.1 ↗ — International Software Testing Qualifications Board · ISTQB CTFL v4.0.1, 15 September 2024; publisher PDF opened 6 November 2026. Sections 1.4.4 and 4.2–4.4 distinguish exercised coverage items, invalid isolation, branches and experience-based techniques.

    Certification curriculum guidance on traceability, partitions, boundaries, decision tables, state transitions, structural coverage and experience-based testing; not a universal product contract. · Checked 2026-11-06

    Version 4.0.1, 15 September 2024. Publisher PDF opened 6 November 2026. Paraphrased for teaching; no licence claim.

Deepest material on this page: L4 — Standards & sources. Where a topic stops short of implementation depth, that is a deliberate coverage decision, not an oversight — see coverage.