Pairwise Testing Generator

Runs in browser Test Design

Reduce combinatorial explosion: enter parameters and values (browser, OS, role, payment method…) and get an all-pairs test matrix with coverage statistics and constraints support.

Privacy: This tool runs entirely in your browser. Your input never leaves your device.
Loading tool…

How to use Pairwise Testing Generator

  1. Enter parameters as "Name: value1, value2, value3", one per line.
  2. Add constraints for impossible combinations if needed.
  3. Generate and check the coverage stats; export the table as CSV or JSON.

Pairwise Testing Generator features

  • All-pairs generation with an IPO-style greedy algorithm
  • Constraints: IF A = x THEN B <> y, forced pairs and forbidden combinations
  • Coverage statistics: tests, exhaustive count, reduction and pairs covered
  • Numbered table, CSV and JSON exports
  • Handles up to 30 parameters and 400 values

Pairwise Testing Generator example

Browser × OS × role matrix

Input:

Browser: Chrome, Firefox, Safari
OS: Windows, macOS, Linux
Role: admin, user
Constraint: IF OS = Linux THEN Browser <> Safari

Output:

#  Browser  OS       Role
1  Chrome   Windows  admin
2  Firefox  macOS    admin
3  Safari   Windows  user
… 9–10 tests instead of 18; pairs covered 100%

Frequently asked questions about Pairwise Testing Generator

What is pairwise testing?

A combinatorial technique that guarantees every pair of parameter values appears in at least one test. Most defects involve one or two factors, so all-pairs finds them with a fraction of the exhaustive combinations.

How do I add constraints?

Use "IF OS = iOS THEN Browser <> Edge" to exclude a pair, "IF A = x THEN B = y" to force one, or "A = x AND B = y" to forbid a combination. Constraints are respected during generation and impossible pairs are reported.

How good is the reduction?

For 4×5×3×3×3 values the exhaustive set is 540 tests; the pairwise set is usually 20–25. The stats show the exact reduction and the number of value pairs covered.

Is the algorithm the same as PICT?

It is an IPO-style greedy generator similar in spirit to PICT and AllPairs. Results are minimal-ish rather than provably minimal; run it again after reordering parameters to compare sizes.

Technical notes

Generation is deterministic: identical input always yields the same table. All value pairs are enumerated first, minus those a constraint forbids on their own. Each row starts from the first uncovered pair, then fills the remaining parameters in input order with the value covering the most still-uncovered pairs against cells already fixed, ties going to the earlier value. Rows that violate a constraint or add nothing are dropped; generation stops at 5,000 rows.

Coverage is 2-way: every allowed pair appears at least once, no 3-way targeting, and row count is not proven minimal but never below the product of the two largest domains (5 × 4 = 20 for the sample). IF A = x THEN B = y expands to one forbidden pair per other value of B; forbidden combinations spanning 3+ parameters exclude rows but not pairs. Exhaustive count and reduction ignore constraints.