Morrow CreekData Services
← Morrow Creek Data Journal

How to Define Acceptance Tests for a Business Dataset Before It Enters Production

Morrow Creek Data ServicesMorrow Creek Data Journal

A dataset is not ready for production because it looks clean in a spreadsheet or because a pipeline completed without errors. It is ready when it has kept the promises needed for people to rely on it.

Those promises should be written before release. They turn “the data looks good” into a decision that can be repeated, reviewed, and defended.

The starting point is not a generic quality score. It is the business use. A dataset supporting daily renewal outreach has different requirements from one used for quarterly trend analysis. A one-day delay might make the first unsafe, while it has little consequence for the second.

Start with purpose and row definition

Write two short statements before defining any checks:

  • Purpose: What decision or process will this dataset support?
  • Grain: What does one row represent?

For example:

> This dataset supports nightly renewal outreach. One row represents one active customer account at the nightly cutoff.

That grain statement matters. “Account ID must be unique” is a valid requirement for this example. It would not be valid for a transaction table, where several rows per account may be expected.

Purpose and grain also clarify what counts as a meaningful failure. A blank contact field may be a release blocker for an outreach list. It may be an acceptable limitation in a financial reconciliation dataset that does not use contact information.

Define a small set of observable promises

A practical acceptance suite usually covers six areas.

Delivery and schema. Did the expected file, table, or extract arrive? Are required columns present, named correctly, and supplied in usable types or formats?

Required fields. Are fields needed for the stated use populated where they should be? This is more precise than demanding that every field be nonblank.

Identity and relationships. Are identifiers unique where the grain requires uniqueness? Do records that require a parent organization, product, or account link to a valid parent record?

Business-rule validity. Do values follow the rules the business has defined? For example, account_status might be limited to an approved set of values. A cross-field rule could require a populated cancellation date when status is Cancelled, and a blank cancellation date when status is Active.

Coverage and reconciliation. Does the dataset represent the population it claims to represent? Are all expected regions, reporting periods, or source feeds present? Where an independent control total exists, does the published count reconcile with it?

Freshness. Is the information recent enough for the intended decision? Specify which timestamp matters: event time, source-update time, ingestion time, or publication time. They answer different questions.

Completeness of fields is not completeness of a dataset. A table can have every required cell populated while omitting an entire region or source feed.

Make each test release-ready

For every test, document six things:

1. What is tested? 2. What population does it cover? 3. What is the pass rule or threshold? 4. Is the result a blocker or a warning? 5. Who owns the response? 6. What happens if it fails?

A compact acceptance sheet might include these columns:

Test IDRuleScopePass thresholdSeverityOwnerFailure action
ACC-01Required columns are presentEntire delivery0 missing columnsBlockData ownerStop release
ACC-02customer_account_id is populated and uniqueActive accounts0 exceptionsBlockData ownerStop release
ACC-03account_status is an approved valueActive accounts0 exceptionsBlockBusiness ownerStop release
ACC-04Required parent organizations existAccounts requiring a parent0 unmatched recordsBlockSource ownerStop release or quarantine affected rows
ACC-05Active-account total reconciles by regionEach regionWithin 0.5% of source control totalReviewBusiness ownerDocument decision
ACC-06Latest source event is recent enoughEntire deliveryNo more than 24 hours oldBlockOperations ownerStop release

The numbers above are examples, not universal standards. A 0.5% reconciliation tolerance may be too loose for a billing dataset and too strict for a preliminary market estimate. The acceptable limit depends on the source process, the decision, and the harm a wrong result could cause.

Separate hard gates from review signals

Not every unusual result should automatically block publication.

Some checks are deterministic. A required column is either absent or present. A supposed primary key is either duplicated or not. These often make good hard gates.

Other checks signal a condition that needs judgment. A 12% increase in weekly row count could indicate a missing filter, a duplicated feed, or a legitimate acquisition. A substantial variance is useful to surface, but it may require an accountable person to decide whether release remains appropriate.

This distinction prevents two common mistakes: releasing data with known structural defects, and halting useful data because a real-world change looks statistically unusual.

Decide the exception path before the first failure

“Investigate” is not a release decision. Define the available dispositions before launch:

  • block publication;
  • quarantine the affected rows;
  • release with a documented limitation; or
  • approve a time-limited exception.

For a review failure, retain the failed rule, affected count, likely cause, decision owner, approval date, and expiry date. An exception without an expiry date has a habit of becoming an undocumented permanent rule.

Automated tests can confirm conformance with stated requirements. They cannot alone prove that a value is true in the real world. An email that matches a pattern may still be undeliverable. Accuracy may require comparison with an authoritative source, a sample review, or domain expertise.

Acceptance testing is therefore not a claim that a dataset is perfect. It is a clear statement of what must be true before this particular dataset can be used for this particular purpose.

Treat that statement as versioned business policy. When the source changes, a new region is added, definitions shift, or the dataset gains a new use, revisit the tests. A dataset that passes last month’s acceptance suite is not automatically approved for a changed job.

Have a dataset that needs to become usable?

Morrow Creek Data Services handles paid research, cleanup, verification, and structured delivery projects.

Start a data project