@@ -14,29 +14,23 @@ If PageObject is generated globally it will act as UIMap, without any logic in i
14
14
* ` codecept g:page Registration `
15
15
* ` codecept g:page acceptance Login `
16
16
17
-
18
-
19
17
## GherkinSnippets
20
18
21
19
Generates code snippets for matched feature files in a suite.
22
20
Code snippets are expected to be implemented in Actor or PageObjects
23
21
24
22
Usage:
25
23
26
- * ` codecept gherkin:snippets acceptance ` - snippets from all feature of acceptance tests
27
- * ` codecept gherkin:snippets acceptance/feature/users ` - snippets from ` feature/users ` dir of acceptance tests
28
- * ` codecept gherkin:snippets acceptance user_account.feature ` - snippets from a single feature file
29
- * ` codecept gherkin:snippets acceptance/feature/users/user_accout.feature ` - snippets from feature file in a dir
30
-
31
-
24
+ * ` codecept gherkin:snippets Acceptance ` - snippets from all feature of acceptance tests
25
+ * ` codecept gherkin:snippets Acceptance/feature/users ` - snippets from ` feature/users ` dir of acceptance tests
26
+ * ` codecept gherkin:snippets Acceptance user_account.feature ` - snippets from a single feature file
27
+ * ` codecept gherkin:snippets Acceptance/feature/users/user_accout.feature ` - snippets from feature file in a dir
32
28
33
29
## Console
34
30
35
31
Try to execute test commands in run-time. You may try commands before writing the test.
36
32
37
- * ` codecept console acceptance ` - starts acceptance suite environment. If you use WebDriver you can manipulate browser with Codeception commands.
38
-
39
-
33
+ * ` codecept console Acceptance ` - starts acceptance suite environment. If you use WebDriver you can manipulate browser with Codeception commands.
40
34
41
35
## GenerateSnapshot
42
36
@@ -48,34 +42,29 @@ If suite name is provided, an actor class will be included into placeholder
48
42
* ` codecept g:snapshot Products `
49
43
* ` codecept g:snapshot acceptance UserEmails `
50
44
51
-
52
-
53
45
## GenerateHelper
54
46
55
47
Creates empty Helper class.
56
48
57
49
* ` codecept g:helper MyHelper `
58
50
* ` codecept g:helper "My\Helper" `
59
51
60
-
61
-
62
-
63
52
## Run
64
53
65
54
Executes tests.
66
55
67
56
Usage:
68
57
69
- * ` codecept run acceptance ` : run all acceptance tests
70
- * ` codecept run tests/acceptance /MyCest.php ` : run only MyCest
71
- * ` codecept run acceptance MyCest ` : same as above
72
- * ` codecept run acceptance MyCest:myTestInIt ` : run one test from a Cest
73
- * ` codecept run acceptance MyCest:myTestInIt#1 ` : run one example or data provider item by number
74
- * ` codecept run acceptance MyCest:myTestInIt#1-3 ` : run a range of examples or data provider items
75
- * ` codecept run acceptance MyCest:myTestInIt@name.* ` : run data provider items with matching names
76
- * ` codecept run acceptance checkout.feature ` : run feature-file
77
- * ` codecept run acceptance -g slow ` : run tests from * slow* group
78
- * ` codecept run unit,functional ` : run only unit and functional suites
58
+ * ` codecept run Acceptance ` : run all acceptance tests
59
+ * ` codecept run tests/Acceptance /MyCest.php ` : run only MyCest
60
+ * ` codecept run Acceptance MyCest ` : same as above
61
+ * ` codecept run Acceptance MyCest:myTestInIt ` : run one test from a Cest
62
+ * ` codecept run Acceptance MyCest:myTestInIt#1 ` : run one example or data provider item by number
63
+ * ` codecept run Acceptance MyCest:myTestInIt#1-3 ` : run a range of examples or data provider items
64
+ * ` codecept run Acceptance MyCest:myTestInIt@name.* ` : run data provider items with matching names
65
+ * ` codecept run Acceptance checkout.feature ` : run feature-file
66
+ * ` codecept run Acceptance -g slow ` : run tests from * slow* group
67
+ * ` codecept run Unit,Functional ` : run only unit and functional suites
79
68
80
69
Verbosity modes:
81
70
@@ -145,9 +134,6 @@ Options:
145
134
146
135
{% endhighlight %}
147
136
148
-
149
-
150
-
151
137
## Bootstrap
152
138
153
139
Creates default config, tests directory and sample suites for current project.
@@ -161,9 +147,6 @@ By default it will create 3 suites **Acceptance**, **Functional**, and **Unit**.
161
147
* ` codecept bootstrap --actor Wizard ` - sets actor as Wizard, to have ` TestWizard ` actor in tests.
162
148
* ` codecept bootstrap path/to/the/project ` - provide different path to a project, where tests should be placed
163
149
164
-
165
-
166
-
167
150
## SelfUpdate
168
151
169
152
Auto-updates phar archive from official site: 'https://codeception.com/codecept.phar ' .
@@ -172,17 +155,12 @@ Auto-updates phar archive from official site: 'https://codeception.com/codecept.
172
155
173
156
@author Franck Cassedanne
< [email protected] >
174
157
175
-
176
-
177
158
## GenerateGroup
178
159
179
160
Creates empty GroupObject - extension which handles all group events.
180
161
181
162
* ` codecept g:group Admin `
182
163
183
-
184
-
185
-
186
164
## GherkinSteps
187
165
188
166
Prints all steps from all Gherkin contexts for a specific suite
@@ -192,13 +170,8 @@ codecept gherkin:steps acceptance
192
170
193
171
{% endhighlight %}
194
172
195
-
196
-
197
-
198
173
## Init
199
174
200
-
201
-
202
175
## GenerateEnvironment
203
176
204
177
Generates empty environment configuration file into envs dir:
@@ -207,27 +180,20 @@ Generates empty environment configuration file into envs dir:
207
180
208
181
Required to have ` envs ` path to be specified in ` codeception.yml `
209
182
210
-
211
-
212
183
## GenerateScenarios
213
184
214
185
Generates user-friendly text scenarios from scenario-driven tests (Cest).
215
186
216
- * ` codecept g:scenarios acceptance ` - for all acceptance tests
217
- * ` codecept g:scenarios acceptance --format html ` - in html format
218
- * ` codecept g:scenarios acceptance --path doc ` - generate scenarios to ` doc ` dir
219
-
220
-
187
+ * ` codecept g:scenarios Acceptance ` - for all acceptance tests
188
+ * ` codecept g:scenarios Acceptance --format html ` - in html format
189
+ * ` codecept g:scenarios Acceptance --path doc ` - generate scenarios to ` doc ` dir
221
190
222
191
## GenerateStepObject
223
192
224
193
Generates StepObject class. You will be asked for steps you want to implement.
225
194
226
- * ` codecept g:stepobject acceptance AdminSteps `
227
- * ` codecept g:stepobject acceptance UserSteps --silent ` - skip action questions
228
-
229
-
230
-
195
+ * ` codecept g:stepobject Acceptance AdminSteps `
196
+ * ` codecept g:stepobject Acceptance UserSteps --silent ` - skip action questions
231
197
232
198
## GenerateTest
233
199
@@ -236,8 +202,6 @@ Generates skeleton for Unit Test that extends `Codeception\TestCase\Test`.
236
202
* ` codecept g:test unit User `
237
203
* ` codecept g:test unit "App\User" `
238
204
239
-
240
-
241
205
## ConfigValidate
242
206
243
207
Validates and prints Codeception config.
@@ -259,9 +223,6 @@ Check overriding config values (like in `run` command)
259
223
* ` codecept config:validate -o "settings: lint: false" ` : disable linting
260
224
* ` codecept config:validate -o "reporters: report: \Custom\Reporter" --report ` : use custom reporter
261
225
262
-
263
-
264
-
265
226
## Build
266
227
267
228
Generates Actor classes (initially Guy classes) from suite configs.
@@ -270,9 +231,6 @@ Starting from Codeception 2.0 actor classes are auto-generated. Use this command
270
231
* ` codecept build `
271
232
* ` codecept build path/to/project `
272
233
273
-
274
-
275
-
276
234
## GenerateSuite
277
235
278
236
Create new test suite. Requires suite name and actor name
@@ -282,9 +240,6 @@ Create new test suite. Requires suite name and actor name
282
240
* ` codecept g:suite integration Code ` -> integration + CodeTester
283
241
* ` codecept g:suite frontend Front ` -> frontend + FrontTester
284
242
285
-
286
-
287
-
288
243
## GenerateFeature
289
244
290
245
Generates Feature file (in Gherkin):
@@ -293,30 +248,21 @@ Generates Feature file (in Gherkin):
293
248
* ` codecept g:feature suite subdir/subdir/login.feature `
294
249
* ` codecept g:feature suite login.feature -c path/to/project `
295
250
296
-
297
-
298
-
299
251
## DryRun
300
252
301
253
Shows step by step execution process for scenario driven tests without actually running them.
302
254
303
- * ` codecept dry-run acceptance `
304
- * ` codecept dry-run acceptance MyCest `
305
- * ` codecept dry-run acceptance checkout.feature `
306
- * ` codecept dry-run tests/acceptance/MyCest.php `
307
-
308
-
309
-
255
+ * ` codecept dry-run Acceptance `
256
+ * ` codecept dry-run Acceptance MyCest `
257
+ * ` codecept dry-run Acceptance checkout.feature `
258
+ * ` codecept dry-run tests/Acceptance/MyCest.php `
310
259
311
260
## Clean
312
261
313
262
Recursively cleans ` output ` directory and generated code.
314
263
315
264
* ` codecept clean `
316
265
317
-
318
-
319
-
320
266
## GenerateCest
321
267
322
268
Generates Cest (scenario-driven object-oriented test) file:
@@ -326,10 +272,4 @@ Generates Cest (scenario-driven object-oriented test) file:
326
272
* ` codecept g:cest suite LoginCest -c path/to/project `
327
273
* ` codecept g:cest "App\Login" `
328
274
329
-
330
-
331
-
332
275
## CompletionFallback
333
-
334
-
335
-
0 commit comments