github.com/data-DOG/godog@v0.7.9/features/run.feature (about) 1 Feature: run features 2 In order to test application behavior 3 As a test suite 4 I need to be able to run features 5 6 Scenario: should run a normal feature 7 Given a feature "normal.feature" file: 8 """ 9 Feature: normal feature 10 11 Scenario: parse a scenario 12 Given a feature path "features/load.feature:6" 13 When I parse features 14 Then I should have 1 scenario registered 15 """ 16 When I run feature suite 17 Then the suite should have passed 18 And the following steps should be passed: 19 """ 20 a feature path "features/load.feature:6" 21 I parse features 22 I should have 1 scenario registered 23 """ 24 25 Scenario: should skip steps after failure 26 Given a feature "failed.feature" file: 27 """ 28 Feature: failed feature 29 30 Scenario: parse a scenario 31 Given a failing step 32 When I parse features 33 Then I should have 1 scenario registered 34 """ 35 When I run feature suite 36 Then the suite should have failed 37 And the following step should be failed: 38 """ 39 a failing step 40 """ 41 And the following steps should be skipped: 42 """ 43 I parse features 44 I should have 1 scenario registered 45 """ 46 47 Scenario: should skip all scenarios if background fails 48 Given a feature "failed.feature" file: 49 """ 50 Feature: failed feature 51 52 Background: 53 Given a failing step 54 55 Scenario: parse a scenario 56 Given a feature path "features/load.feature:6" 57 When I parse features 58 Then I should have 1 scenario registered 59 """ 60 When I run feature suite 61 Then the suite should have failed 62 And the following step should be failed: 63 """ 64 a failing step 65 """ 66 And the following steps should be skipped: 67 """ 68 a feature path "features/load.feature:6" 69 I parse features 70 I should have 1 scenario registered 71 """ 72 73 Scenario: should skip steps after undefined 74 Given a feature "undefined.feature" file: 75 """ 76 Feature: undefined feature 77 78 Scenario: parse a scenario 79 Given a feature path "features/load.feature:6" 80 When undefined action 81 Then I should have 1 scenario registered 82 """ 83 When I run feature suite 84 Then the suite should have passed 85 And the following step should be passed: 86 """ 87 a feature path "features/load.feature:6" 88 """ 89 And the following step should be undefined: 90 """ 91 undefined action 92 """ 93 And the following step should be skipped: 94 """ 95 I should have 1 scenario registered 96 """ 97 98 Scenario: should match undefined steps in a row 99 Given a feature "undefined.feature" file: 100 """ 101 Feature: undefined feature 102 103 Scenario: parse a scenario 104 Given undefined step 105 When undefined action 106 Then I should have 1 scenario registered 107 """ 108 When I run feature suite 109 Then the suite should have passed 110 And the following steps should be undefined: 111 """ 112 undefined step 113 undefined action 114 """ 115 And the following step should be skipped: 116 """ 117 I should have 1 scenario registered 118 """ 119 120 Scenario: should skip steps on pending 121 Given a feature "pending.feature" file: 122 """ 123 Feature: pending feature 124 125 Scenario: parse a scenario 126 Given undefined step 127 When pending step 128 Then I should have 1 scenario registered 129 """ 130 When I run feature suite 131 Then the suite should have passed 132 And the following step should be undefined: 133 """ 134 undefined step 135 """ 136 And the following step should be skipped: 137 """ 138 pending step 139 I should have 1 scenario registered 140 """ 141 142 Scenario: should handle pending step 143 Given a feature "pending.feature" file: 144 """ 145 Feature: pending feature 146 147 Scenario: parse a scenario 148 Given a feature path "features/load.feature:6" 149 When pending step 150 Then I should have 1 scenario registered 151 """ 152 When I run feature suite 153 Then the suite should have passed 154 And the following step should be passed: 155 """ 156 a feature path "features/load.feature:6" 157 """ 158 And the following step should be pending: 159 """ 160 pending step 161 """ 162 And the following step should be skipped: 163 """ 164 I should have 1 scenario registered 165 """ 166 167 Scenario: should mark undefined steps after pending 168 Given a feature "pending.feature" file: 169 """ 170 Feature: pending feature 171 172 Scenario: parse a scenario 173 Given pending step 174 When undefined 175 Then undefined 2 176 And I should have 1 scenario registered 177 """ 178 When I run feature suite 179 Then the suite should have passed 180 And the following steps should be undefined: 181 """ 182 undefined 183 undefined 2 184 """ 185 And the following step should be pending: 186 """ 187 pending step 188 """ 189 And the following step should be skipped: 190 """ 191 I should have 1 scenario registered 192 """ 193 194 Scenario: should fail suite if undefined steps follow after the failure 195 Given a feature "failed.feature" file: 196 """ 197 Feature: failed feature 198 199 Scenario: parse a scenario 200 Given a failing step 201 When an undefined step 202 Then another undefined step 203 """ 204 When I run feature suite 205 Then the following step should be failed: 206 """ 207 a failing step 208 """ 209 And the following steps should be undefined: 210 """ 211 an undefined step 212 another undefined step 213 """ 214 And the suite should have failed 215 216 Scenario: should fail suite and skip pending step after failed step 217 Given a feature "failed.feature" file: 218 """ 219 Feature: failed feature 220 221 Scenario: parse a scenario 222 Given a failing step 223 When pending step 224 Then another undefined step 225 """ 226 When I run feature suite 227 Then the following step should be failed: 228 """ 229 a failing step 230 """ 231 And the following steps should be skipped: 232 """ 233 pending step 234 """ 235 And the following steps should be undefined: 236 """ 237 another undefined step 238 """ 239 And the suite should have failed 240 241 Scenario: should fail suite and skip next step after failed step 242 Given a feature "failed.feature" file: 243 """ 244 Feature: failed feature 245 246 Scenario: parse a scenario 247 Given a failing step 248 When a failing step 249 Then another undefined step 250 """ 251 When I run feature suite 252 Then the following step should be failed: 253 """ 254 a failing step 255 """ 256 And the following steps should be skipped: 257 """ 258 a failing step 259 """ 260 And the following steps should be undefined: 261 """ 262 another undefined step 263 """ 264 And the suite should have failed