Pairwise Test Generator

No data sent

Generate pairwise (all-pairs) and n-wise test cases in your browser. Enter the parameters in a grid, or write a Microsoft PICT model as text, with constraints, sub-models, aliases, weights and negative values. Copy the result to a spreadsheet or download it as CSV, TSV, JSON or JSON Lines.

About this tool

What is pairwise testing?

Testing every combination of inputs quickly becomes impossible: 5 devices × 2 operating systems × 3 browsers × 5 versions is already 150 cases. Pairwise testing (all-pairs testing) instead picks a small set of cases in which every pair of values from any two parameters appears at least once. Many defects are caused by the interaction of just two settings, so this catches most of them with far fewer tests.

You can also raise the strength to 3-wise or higher to cover every combination of three or more parameters. The test sets (covering arrays) are built with the covertable library.

How to use

  1. Choose how to enter the parameters with Grid or Text:
    • Grid: enter a parameter name in column A and its values in the cells to the right, one parameter per row, and write constraints below.
    • Text: write a Microsoft PICT model, or pick one from Samples.
  2. Optionally change the Strength (2 = pairwise, 3 = 3-wise, …) and the other options.
  3. Click Generate. Large models or higher strengths can take a while; click Stop to cancel.
  4. Switch between Table, CSV, TSV, JSON and JSONL, then Copy or Download the result.

Switching between Grid and Text converts the contents. The grid can only hold plain parameters, so a model that uses aliases, weights, negative values, sub-models or formula columns stays in Text.

PICT model format

# Parameters: name, colon, comma-separated values
Type:   Single, Span, Stripe, Mirror, RAID-5
Size:   10, 100, 500, 1000, 5000
File system: FAT, FAT32, NTFS

# Constraints
IF [File system] = "FAT" THEN [Size] <= 4096;
SyntaxMeaning
Name: a, b, cA parameter and its values ("a, b" for a value with a comma)
~valueNegative value: at most one per row, to test error cases one at a time
a | bAliases: any name can be used in constraints; the first is output
value (N)Weight: makes the value more likely when rows are filled in
{ A, B, C } @ 3Sub-model: cover these parameters with a different strength
Name: =FORMULA([A], [B])Formula column: output on every row with [A] replaced by that row's cell (A1, B2, …)
IF … THEN … ELSE …;Constraint
=, <>, >, <, >=, <=Comparisons (text values in double quotes)
IN {"a", "b"}, LIKE "ab*"Set membership, wildcard match (* any text, ? one character)
AND, OR, NOT, ( )Combine conditions
+, -, *, /, %Arithmetic, e.g. [A] * [B] > 100
# commentComment line

Problems in the model are listed under the editor, and the lines with errors are highlighted.

Options

  • Strength: the number of parameters whose combinations are all covered. 2 is pairwise. Higher strengths give many more rows and take longer.
  • Criterion: Greedy picks the pairs that cover the most at each step (fewer rows). Simple is faster on very large models.
  • Randomize: by default the same input always gives the same result. Turn this on to get a different set each time.
  • Case sensitive: compare values in constraints with case (PICT ignores case by default).
  • Optimize: after generating, shrink the result with simulated annealing for the chosen time. Coverage and constraints are kept, but weights are ignored.

FAQ

Is it compatible with Microsoft PICT?

It reads the PICT model format, including constraints, sub-models, aliases, weights and negative values. It also accepts a few extensions that PICT does not: arithmetic in constraints, # comments inside constraints, and formula columns. Models that use them will not run in the original PICT. The rows generated are not identical to PICT's, but they cover the same combinations.

How many test cases will I get?

It depends on the parameters, especially the two with the most values: pairwise testing needs at least (values of the largest parameter) × (values of the second largest) cases. The generator is greedy, so the result is small but not always the minimum; Optimize can shrink it further.

Why do I get "Only N% of the required combinations could be covered"?

Your constraints rule out some value pairs entirely, so they can never appear. Check that the rules are what you intended. "Pruned" in the result counts these pairs.

Is my data sent to a server?

No. Generation runs entirely in your browser.

📝 Dummy Text Generator
Generate placeholder text for designs and layout tests: classic Lorem ipsum, English-like sentences, natural-looking Japanese (ダミーテキスト), or repeating fill patterns such as 「あ」 and 1234567890.
📱 QR Code Generator
Create a QR code from any text or URL. Set the size, colors and error correction level, add a logo in the center, and download it as a PNG image.
🎡 Roulette Wheel
Make your own roulette wheel: enter names or choices, spin, and a winner is picked fairly with your browser's secure random generator.
🆔 ULID Generator
Generate ULIDs: 26-character IDs made of a millisecond timestamp and 80 random bits in Crockford Base32. Create up to 10,000 at once, in increasing order.
🆔 UUID v1 Generator
Generate up to 10,000 time-based UUID v1 values at once from the current timestamp, a clock sequence and a random node ID. Copy them or download a .txt file.
🆔 UUID v3 Generator
Create a name-based UUID v3 by hashing a namespace and a name with MD5. Pick the DNS, URL, OID or X.500 namespace or paste your own; same input, same UUID.