@@ -14,14 +14,14 @@ Feature: Retry failing tests
14
14
Given a scenario "Fails-once" that fails once, then passes
15
15
And a scenario "Fails-twice" that fails twice, then passes
16
16
And a scenario "Solid" that passes
17
- And a scenario "Fails-forever" that fails
18
17
19
18
@todo-windows
20
19
Scenario : Retry once, so Fails-once starts to pass
20
+ Given a scenario "Fails-forever" that fails
21
21
When I run `cucumber -q --retry 1 --format summary`
22
22
Then it should fail with:
23
23
"""
24
- 7 scenarios (5 failed, 2 passed)
24
+ 4 scenarios (2 failed, 1 flaky, 1 passed)
25
25
"""
26
26
And it should fail with:
27
27
"""
@@ -43,10 +43,11 @@ Feature: Retry failing tests
43
43
44
44
@todo-windows
45
45
Scenario : Retry twice, so Fails-twice starts to pass too
46
+ Given a scenario "Fails-forever" that fails
46
47
When I run `cucumber -q --retry 2 --format summary`
47
48
Then it should fail with:
48
49
"""
49
- 9 scenarios (6 failed, 3 passed)
50
+ 4 scenarios (1 failed, 2 flaky, 1 passed)
50
51
"""
51
52
And it should fail with:
52
53
"""
@@ -67,3 +68,25 @@ Feature: Retry failing tests
67
68
Fails-twice ✗
68
69
Fails-twice ✓
69
70
"""
71
+
72
+ @todo-windows
73
+ Scenario : Flaky scenarios gives exit code zero in non-strict mode
74
+ When I run `cucumber -q --retry 2 --format summary`
75
+ Then it should pass with:
76
+ """
77
+
78
+
79
+ 3 scenarios (2 flaky, 1 passed)
80
+ """
81
+
82
+ @todo-windows
83
+ Scenario : Flaky scenarios gives non-zero exit code in strict mode
84
+ When I run `cucumber -q --retry 2 --format summary --strict`
85
+ Then it should fail with:
86
+ """
87
+ Flaky Scenarios:
88
+ cucumber features/fails_once.feature:2
89
+ cucumber features/fails_twice.feature:2
90
+
91
+ 3 scenarios (2 flaky, 1 passed)
92
+ """
0 commit comments