Skip to content

Examples

William Niemiec edited this page Aug 25, 2021 · 1 revision

📊 Examples

Some examples of test path generation. You can check out more examples here (which was generated using the structure shown in the section output)


Inline if-else

if-else-same-line

Input Generated test path
-1 [213, 215,216, 218]
1 [213, 214, 218]

If-else

if-else

Input Generated test path
-1 [11, 12]
0 [11, 15, 17, 18, 25]
1 [11, 15, 17, 19, 20, 25]
2 [11, 15, 17, 19, 21, 22, 25]

Switch

switch

Input Generated test path
'É' [64, 66, 73, 74, 75, 76, 77, 96]

Try-catch - try

try-catch_try

Input Generated test path
[30, 32, 33, 34, 35, 36, 37, 42]

Try-catch - catch

try-catch_catch

Input Generated test path
[47, 49, 50, 51, 52, 53]

Do while

do-while

Input Generated test path
(1,3) [101, 103, 106, 107, 108, 109, 106, 107, 108, 109, 106, 107, 108, 109, 111]
(0,99) [101, 102]
(99,0) [101, 103, 104]
(2,5) [101, 103, 106, 107, 108, 109, 106, 107, 108, 109, 106, 107, 108, 109, 106, 107, 108, 109, 106, 107, 108, 109, 111]
Clone this wiki locally