clement13.net
Original photo: Deux poids en laiton couverts de poinçons de vérification : la conformité attestée avant l'usage
Description
Deux poids en laiton couverts de poinçons de vérification : la conformité attestée avant l'usage
Source
HelgeRieder · original page
Licence
CC0 Public domain
Original photo, unretouched. The background is a version of it stylised by the site.

Acceptance testing and business validation

“The code runs without errors” does not mean “the number is correct.” In data, acceptance testing has a specific nature: you don't verify a function, you verify a number against an…

Guide≈ 7 min readCheckedCheck doneFacts, figures and references were checked against the sources cited in the page.Written with AI assistance; sources are cited at the bottom of the page. An error? Report it via clement13.net.Reading

Level: 🟢→🔴 · Theme code: REC

Why this theme#

“The code runs without errors” does not mean “the number is correct.” In data, acceptance testing has a specific nature: you don't verify a function, you verify a number against an independent reference (an accounting statement, an export from the source application, an expert's manual calculation). Without it, trust is based on the absence of complaints. With it, you can say: “this number matches the reference within 0.1%; here is the explained and signed-off gap.” It is the last line of defense before a decision. This theme is distinct from code testing (DL — Testing), model and measure testing (BI — Testing and Metrics Reliability), and quality (QUA): here, it's about business validation on numbers, its evidence, and its sign-off.

What this theme measures#

  • Axis: from a feeling of correctness to continuous reconciliation against independent references.
  • Key indicator: share of critical indicators reconciled with an independent reference, and explained residual gap.
  • Unit: % of reconciled indicators; maximum tolerated relative gap (e.g., 0.1%); number of escaped defects detected in production.

The five levels#

Level Short name Promise Typical indicator (orders of magnitude)
1 Impression The requester looks at the report and says whether it seems correct. 0 independent reference
2 Sample A few key figures are matched against a reference source at each delivery. ≥ 5 key figures compared, manually
3 Plan An acceptance testing plan defines indicators, references, tolerances, and sign-off owner; it is executed and archived. 100% of critical indicators in the plan; gaps explained
4 Automated Reconciliation is automatic and replayed with each version: a change that modifies a figure is visible before production. Figure non-regression at each delivery; escaped defects < 1 per quarter
5 Continuous Production is continuously reconciled; gaps alert the owner before the user sees them. Daily reconciliation; gap detected < 24 h

Milestones by level#

ID Milestone Verifiable evidence
PD-REC-1.1 Acceptance testing is done before release to users. Record of validation by the requester.
PD-REC-1.2 The acceptance testing scope (reports, periods, filters) is documented. Acceptance note or ticket.
PD-REC-1.3 Issues found during acceptance testing are logged and fixed before delivery. Issue list with status.
PD-REC-1.4 Acceptance testing is done on test environment data, not production alone. Identified acceptance environment.
PD-REC-2.1 At least five key figures are compared with a reference source (source application, accounting statement). Table “report figure / reference figure / gap.”
PD-REC-2.2 The reference is independent from the calculation being tested (neither the same query nor the same model). Description of the reference origin.
PD-REC-2.3 Non-zero gaps are explained (rounding, scope, date shift). “explanation” column filled for each gap.
PD-REC-2.4 The acceptance testing result is archived with the tested version. Acceptance file linked to the delivered version.
PD-REC-3.1 An acceptance testing plan lists indicators, references, test periods, tolerances, and roles. Versioned plan with owner.
PD-REC-3.2 Edge cases are tested: empty period, load replay, year change, negative values, user with restricted permissions. Cases listed with results (RLS is tested on the BI — RLS Security and Access side).
PD-REC-3.3 A business decision-maker signs off acceptance testing (not the technical team alone). Signature (or written approval) from a business stakeholder.
PD-REC-3.4 Acceptance testing covers consistency across reports (same figure, same filters, same result). Cross-test on at least one shared indicator.
PD-REC-4.1 A set of reference figures is stored and replayed automatically with each version. Versioned set executed in the pipeline (DOP).
PD-REC-4.2 A gap exceeding tolerance blocks delivery. A case where blocking actually occurred.
PD-REC-4.3 Figure changes between two versions are listed and explained before publication (result diff). “before/after” report for each version.
PD-REC-4.4 Each escaped production defect creates a new acceptance test case. Link between incident and added case.
PD-REC-5.1 A scheduled reconciliation compares production to references (accounting, application) every day. Reconciliation history with results.
PD-REC-5.2 Gaps trigger an alert to a named owner, with an analysis SLA. Archived alerts and observed timelines.
PD-REC-5.3 The references themselves are validated and their evolution tracked. Reference change log.
PD-REC-5.4 Acceptance testing coverage is measured by critical indicator, not by number of tests. Published coverage, quarterly review.

Detailed reading by level#

🟢 Level 1 — Impression#

  • Signs: “looks right to me”; no record of what was checked; the right number is the one that looks like the previous one.
  • Gain: fast social validation.
  • Does not guarantee: accuracy; a 2% error goes unnoticed.
  • Difficulty: 1/5 · Effort: 1/5.

🟢 Level 2 — Sample#

  • Signs: a table comparing five report figures to those from the source application; gaps are discussed; the file is archived.
  • Gain: most scope or join errors are spotted.
  • Does not guarantee: coverage or repeatability.
  • Difficulty: 2/5 · Effort: 2/5.

🟡 Level 3 — Plan#

  • Signs: versioned plan; edge cases listed; business sign-off; consistency across reports tested.
  • Gain: reproducible acceptance testing, shared responsibility with the business.
  • Does not guarantee: no regression in the next version (manual acceptance testing, therefore expensive to replay).
  • Difficulty: 3/5 · Effort: 3/5.
🧪 Example

Shelf survey entries from an SFA application: the plan sets three references (application export for 10 stores, accounted monthly total, manual calculation by an expert on one product). Tolerance: 0 for counts, 0.1% for calculated measures. Edge cases: product without entry, closed store, entry submitted offline and synced three days later, month change. The 12-entry gap found during acceptance testing came from late-synced entries: rule of assignment to the entry date and not sync date, validated by the business.

🟡 Level 4 — Automated#

  • Signs: a reference figure set runs in the pipeline; a “before/after” result diff is produced for each version; each incident adds a case.
  • Gain: acceptance testing that costs almost nothing to replay; regressions become visible.
  • Does not guarantee: that the reference is correct (an incorrect reference locks in the error).
  • Difficulty: 4/5 · Effort: 4/5.
-- Réconciliation : total du datamart contre la référence source (T-SQL), tolérance 0,1 %
WITH Dm  AS (SELECT SUM(REL_QTE) AS Tot FROM [fact].[Releve] WITH (NOLOCK) WHERE [date] >= '2026-09-01' AND [date] < '2026-10-01'),
     Ref AS (SELECT SUM(QTE)     AS Tot FROM [ref].[ExportApplication] WITH (NOLOCK) WHERE MOIS = '2026-09')
SELECT Dm.Tot AS Datamart, Ref.Tot AS Reference,
       ABS(Dm.Tot - Ref.Tot) * 1.0 / NULLIF(Ref.Tot, 0) AS EcartRelatif,
       CASE WHEN ABS(Dm.Tot - Ref.Tot) * 1.0 / NULLIF(Ref.Tot, 0) <= 0.001 THEN 'OK' ELSE 'ECHEC' END AS Verdict
FROM Dm CROSS JOIN Ref;

🔴 Level 5 — Continuous#

  • Signs: reconciliation runs daily; a gap alerts an owner; coverage is measured by indicator.
  • Gain: trust is built continuously, not at delivery time.
  • Does not guarantee: meaning (perfect reconciliation of a poorly defined indicator does not make it useful; see VAL).
  • Difficulty: 5/5 · Effort: 4/5.

Partial achievement and rating#

Assess based on the five most used indicators. A milestone is worth 1 if all five are covered, 0.5 if two to four, otherwise 0. Without archived evidence, an acceptance milestone is worth 0: acceptance testing without proof did not happen.

A “partial 5”: daily reconciliation covers revenue and main volumes (5.1 at 0.5), alerts reach the owner (5.2 at 1), references are stable but not tracked (5.3 at 0.5), coverage is not measured (5.4 at 0).

⚠️ Pitfall

The reference that is not one: comparing the datamart to a query on… the datamart. Symptom: zero gap, users disagree. Fix: the reference comes from another path (source, accounting, independent calculation).

⚠️ Pitfall

Acceptance testing only on the nominal case: everything is correct except the last day of the month, the restricted-scope user, or replay. Fix: a fixed list of data edge cases (empty period, replay, year change, negative values).

Moving to the next level#

Possible means (optional)

Transition Possible levers
1 → 2 Choose five figures the business knows by heart; compare them to the source at each delivery.
2 → 3 Write the plan with the business stakeholder; add edge cases; get sign-off.
3 → 4 Store reference figures; replay them in the pipeline; produce the before/after diff.
4 → 5 Schedule reconciliation in production; connect the alert to the owner (EXP).

Cross-cutting pitfalls: (1) False positive — 100% success on a non-representative test set. (2) Goodhart — targeting “zero gap” leads to adjusting the reference or widening tolerance; track every tolerance change. (3) Tunnel effect — acceptance testing that is only technical, without a business decision-maker, lets definition errors through (GOV).

🤖 AI

It suggests edge cases, generates reconciliation queries, comments on a result diff. It does not sign off acceptance testing, does not know acceptable tolerance, and can produce a test that always passes. The independent reference and sign-off remain human.

See also#

✻ Written by Claude Sonnet 5.5