Skip to content

pairwise-testing/c-pairwise-jenny

Β 
Β 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

17 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Jenny

Build Status

jenny is tool for generating regression tests. Any time exhaustive testing looks painful due to the combinatorial explosion of features interactions to be tested, consider using jenny. It will cover most of the interactions with far fewer testcases. It can guarantee pairwise testing of all features that can be used together, and it can avoid those feature combinations that cannot.

Learn more about combinatorial testing.

Example

Let's imagine we have a program with three features and various values for each feature:

  • Sex (2): ♀️, ♂️
  • Weather (3): 🌧, β˜€οΈ, πŸŒ₯
  • Mood (3): πŸ€’, 😧, 😴

Jenny can generate combinations:

$ ./jenny -n3 2 3 3
 1a 2a 3a
 1b 2b 3b
 1b 2c 3c
 1a 2b 3c
 1b 2a 3c
 1a 2c 3b
 1b 2b 3a
 1b 2a 3b
 1a 2c 3a
 1a 2a 3b
 1a 2c 3c
 1b 2a 3a
 1a 2b 3b
 1b 2c 3a
 1a 2b 3a
 1b 2b 3c
 1a 2a 3c
 1b 2c 3b

where 3 is a number of features in combination, 2, 3 and 3 are numbers of possible values for the appropriate feature. Total number of possible unique combinations is 18.

$ cat jenny.sed
# number the testcases
=


# Dimension 1
s/ 1a / ♀️ /g
s/ 1b / ♂️ /g

# Dimension 2
s/ 2a / 🌧 /g
s/ 2b / β˜€οΈ /g
s/ 2c / πŸŒ₯ /g

# Dimension 3
s/ 3a / πŸ€’ /g
s/ 3b / 😧 /g
s/ 3c / 😴 /g
$ ./jenny -n3 2 3 3 | sed -f jenny.sed
1  ♀️ 🌧 πŸ€’
2  ♂️ β˜€οΈ 😧
3  ♂️ πŸŒ₯ 😴
4  ♀️ β˜€οΈ 😴
5  ♂️ 🌧 😴
6  ♀️ πŸŒ₯ 😧
7  ♂️ β˜€οΈ πŸ€’
8  ♂️ 🌧 😧
9  ♀️ πŸŒ₯ πŸ€’
10 ♀️ 🌧 😧
11 ♀️ πŸŒ₯ 😴
12 ♂️ 🌧 πŸ€’
13 ♀️ β˜€οΈ 😧
14 ♂️ πŸŒ₯ πŸ€’
15 ♀️ β˜€οΈ πŸ€’
16 ♂️ β˜€οΈ 😴
17 ♀️ 🌧 😴
18 ♂️ πŸŒ₯ 😧

Releases

No releases published

Packages

No packages published

Languages

  • C 50.0%
  • Shell 46.8%
  • sed 2.6%
  • Makefile 0.6%