@@ -16,31 +16,43 @@ codecept gherkin:steps Acceptance
1616
1717
1818
19- ## GenerateSuite
19+ ## GenerateStepObject
2020
21- Create new test suite. Requires suite name and actor name
21+ Generates StepObject class. You will be asked for steps you want to implement.
2222
23- * ``
24- * ` codecept g:suite Api ` -> api + ApiTester
25- * ` codecept g:suite Integration Code ` -> integration + CodeTester
26- * ` codecept g:suite Frontend Front ` -> frontend + FrontTester
23+ * ` codecept g:stepobject Acceptance AdminSteps `
24+ * ` codecept g:stepobject Acceptance UserSteps --silent ` - skip action questions
2725
2826
2927
3028
31- ## GenerateSnapshot
29+ ## Bootstrap
3230
33- Generates Snapshot.
34- Snapshot can be used to test dynamical data.
35- If suite name is provided, an actor class will be included into placeholder
31+ Creates default config, tests directory and sample suites for current project.
32+ Use this command to start building a test suite.
3633
37- * ` codecept g:snapshot UserEmails `
38- * ` codecept g:snapshot Products `
39- * ` codecept g:snapshot Acceptance UserEmails `
34+ By default, it will create 3 suites ** Acceptance** , ** Functional** , and ** Unit** .
35+
36+ * ` codecept bootstrap ` - creates ` tests ` dir and ` codeception.yml ` in current dir.
37+ * ` codecept bootstrap --empty ` - creates ` tests ` dir without suites
38+ * ` codecept bootstrap --namespace Frontend ` - creates tests, and use ` Frontend ` namespace for actor classes and helpers.
39+ * ` codecept bootstrap --actor Wizard ` - sets actor as Wizard, to have ` TestWizard ` actor in tests.
40+ * ` codecept bootstrap path/to/the/project ` - provide different path to a project, where tests should be placed
4041
4142
4243
43- ## Init
44+
45+ ## GherkinSnippets
46+
47+ Generates code snippets for matched feature files in a suite.
48+ Code snippets are expected to be implemented in Actor or PageObjects
49+
50+ Usage:
51+
52+ * ` codecept gherkin:snippets Acceptance ` - snippets from all feature of acceptance tests
53+ * ` codecept gherkin:snippets Acceptance/feature/users ` - snippets from ` feature/users ` dir of acceptance tests
54+ * ` codecept gherkin:snippets Acceptance user_account.feature ` - snippets from a single feature file
55+ * ` codecept gherkin:snippets Acceptance/feature/users/user_accout.feature ` - snippets from feature file in a dir
4456
4557
4658
@@ -137,79 +149,47 @@ Options:
137149
138150
139151
140- ## GenerateGroup
141-
142- Creates empty GroupObject - extension which handles all group events.
143-
144- * ` codecept g:group Admin `
145-
146-
147-
148- ## Bootstrap
149-
150- Creates default config, tests directory and sample suites for current project.
151- Use this command to start building a test suite.
152-
153- By default, it will create 3 suites ** Acceptance** , ** Functional** , and ** Unit** .
154-
155- * ` codecept bootstrap ` - creates ` tests ` dir and ` codeception.yml ` in current dir.
156- * ` codecept bootstrap --empty ` - creates ` tests ` dir without suites
157- * ` codecept bootstrap --namespace Frontend ` - creates tests, and use ` Frontend ` namespace for actor classes and helpers.
158- * ` codecept bootstrap --actor Wizard ` - sets actor as Wizard, to have ` TestWizard ` actor in tests.
159- * ` codecept bootstrap path/to/the/project ` - provide different path to a project, where tests should be placed
160-
161-
162-
163-
164- ## GenerateStepObject
165-
166- Generates StepObject class. You will be asked for steps you want to implement.
167-
168- * ` codecept g:stepobject Acceptance AdminSteps `
169- * ` codecept g:stepobject Acceptance UserSteps --silent ` - skip action questions
170-
171-
172-
173-
174- ## GenerateFeature
152+ ## GenerateCest
175153
176- Generates Feature file (in Gherkin) :
154+ Generates Cest (scenario-driven object-oriented test) file :
177155
178- * ` codecept generate:feature suite Login `
179- * ` codecept g:feature suite subdir/subdir/login.feature `
180- * ` codecept g:feature suite login.feature -c path/to/project `
156+ * ` codecept generate:cest suite Login `
157+ * ` codecept g:cest suite subdir/subdir/testnameCest.php `
158+ * ` codecept g:cest suite LoginCest -c path/to/project `
159+ * ` codecept g:cest "App\Login" `
181160
182161
183162
184163
185- ## Clean
164+ ## GenerateHelper
186165
187- Recursively cleans ` output ` directory and generated code .
166+ Creates empty Helper class .
188167
189- * ` codecept clean `
168+ * ` codecept g:helper MyHelper `
169+ * ` codecept g:helper "My\Helper" `
190170
191171
192172
193173
194- ## GenerateCest
174+ ## GeneratePageObject
195175
196- Generates Cest (scenario-driven object-oriented test) file:
176+ Generates PageObject. Can be generated either globally, or just for one suite.
177+ If PageObject is generated globally it will act as UIMap, without any logic in it.
197178
198- * ` codecept generate:cest suite Login `
199- * ` codecept g:cest suite subdir/subdir/testnameCest.php `
200- * ` codecept g:cest suite LoginCest -c path/to/project `
201- * ` codecept g:cest "App\Login" `
179+ * ` codecept g:page Login `
180+ * ` codecept g:page Registration `
181+ * ` codecept g:page Acceptance Login `
202182
203183
204184
185+ ## Build
205186
206- ## GenerateScenarios
187+ Generates Actor classes (initially Guy classes) from suite configs.
188+ Starting from Codeception 2.0 actor classes are auto-generated. Use this command to generate them manually.
207189
208- Generates user-friendly text scenarios from scenario-driven tests (Cest).
190+ * ` codecept build `
191+ * ` codecept build path/to/project `
209192
210- * ` codecept g:scenarios Acceptance ` - for all acceptance tests
211- * ` codecept g:scenarios Acceptance --format html ` - in html format
212- * ` codecept g:scenarios Acceptance --path doc ` - generate scenarios to ` doc ` dir
213193
214194
215195
@@ -223,24 +203,13 @@ Required to have `envs` path to be specified in `codeception.yml`
223203
224204
225205
226- ## GenerateHelper
227-
228- Creates empty Helper class.
229-
230- * ` codecept g:helper MyHelper `
231- * ` codecept g:helper "My\Helper" `
232-
233-
234-
206+ ## SelfUpdate
235207
236- ## GeneratePageObject
208+ Auto-updates phar archive from official site: ' https://codeception.com/codecept.phar ' .
237209
238- Generates PageObject. Can be generated either globally, or just for one suite.
239- If PageObject is generated globally it will act as UIMap, without any logic in it.
210+ * ` php codecept.phar self-update `
240211
241- * ` codecept g:page Login `
242- * ` codecept g:page Registration `
243- * ` codecept g:page Acceptance Login `
212+ @author Franck Cassedanne < franck@cassedanne.com >
244213
245214
246215
@@ -280,6 +249,24 @@ Check overriding config values (like in `run` command)
280249
281250
282251
252+ ## Init
253+
254+
255+
256+ ## CompletionFallback
257+
258+
259+
260+ ## GenerateScenarios
261+
262+ Generates user-friendly text scenarios from scenario-driven tests (Cest).
263+
264+ * ` codecept g:scenarios Acceptance ` - for all acceptance tests
265+ * ` codecept g:scenarios Acceptance --format html ` - in html format
266+ * ` codecept g:scenarios Acceptance --path doc ` - generate scenarios to ` doc ` dir
267+
268+
269+
283270## Console
284271
285272Try to execute test commands in run-time. You may try commands before writing the test.
@@ -288,51 +275,64 @@ Try to execute test commands in run-time. You may try commands before writing th
288275
289276
290277
291- ## Build
278+ ## Clean
292279
293- Generates Actor classes (initially Guy classes) from suite configs.
294- Starting from Codeception 2.0 actor classes are auto-generated. Use this command to generate them manually.
280+ Recursively cleans ` output ` directory and generated code.
295281
296- * ` codecept build `
297- * ` codecept build path/to/project `
282+ * ` codecept clean `
298283
299284
300285
301286
302- ## GenerateTest
287+ ## GenerateSuite
303288
304- Generates skeleton for Unit Test that extends ` Codeception\TestCase\Test ` .
289+ Create new test suite. Requires suite name and actor name
305290
306- * ` codecept g:test Unit User `
307- * ` codecept g:test Unit "App\User" `
291+ * ``
292+ * ` codecept g:suite Api ` -> api + ApiTester
293+ * ` codecept g:suite Integration Code ` -> integration + CodeTester
294+ * ` codecept g:suite Frontend Front ` -> frontend + FrontTester
308295
309296
310297
311- ## CompletionFallback
312298
299+ ## GenerateGroup
313300
301+ Creates empty GroupObject - extension which handles all group events.
314302
315- ## GherkinSnippets
303+ * ` codecept g:group Admin `
316304
317- Generates code snippets for matched feature files in a suite.
318- Code snippets are expected to be implemented in Actor or PageObjects
319305
320- Usage:
321306
322- * ` codecept gherkin:snippets Acceptance ` - snippets from all feature of acceptance tests
323- * ` codecept gherkin:snippets Acceptance/feature/users ` - snippets from ` feature/users ` dir of acceptance tests
324- * ` codecept gherkin:snippets Acceptance user_account.feature ` - snippets from a single feature file
325- * ` codecept gherkin:snippets Acceptance/feature/users/user_accout.feature ` - snippets from feature file in a dir
307+ ## GenerateTest
326308
309+ Generates skeleton for Unit Test that extends ` Codeception\TestCase\Test ` .
327310
311+ * ` codecept g:test Unit User `
312+ * ` codecept g:test Unit "App\User" `
328313
329- ## SelfUpdate
330314
331- Auto-updates phar archive from official site: 'https://codeception.com/codecept.phar ' .
332315
333- * ` php codecept.phar self-update `
316+ ## GenerateFeature
334317
335- @author Franck Cassedanne < franck@cassedanne.com >
318+ Generates Feature file (in Gherkin):
319+
320+ * ` codecept generate:feature suite Login `
321+ * ` codecept g:feature suite subdir/subdir/login.feature `
322+ * ` codecept g:feature suite login.feature -c path/to/project `
323+
324+
325+
326+
327+ ## GenerateSnapshot
328+
329+ Generates Snapshot.
330+ Snapshot can be used to test dynamical data.
331+ If suite name is provided, an actor class will be included into placeholder
332+
333+ * ` codecept g:snapshot UserEmails `
334+ * ` codecept g:snapshot Products `
335+ * ` codecept g:snapshot Acceptance UserEmails `
336336
337337
338338
0 commit comments