@@ -52,7 +52,7 @@ WP-CLI `packages/local/` directory.
52
52
[--require_wp_cli=<version>]
53
53
Required WP-CLI version for the package.
54
54
---
55
- default: >= 1.1.0
55
+ default: ^ 1.1.0
56
56
---
57
57
58
58
[--skip-tests]
@@ -75,9 +75,9 @@ wp scaffold package-tests <dir> [--ci=<provider>] [--force]
75
75
~~~
76
76
77
77
WP-CLI makes use of a Behat-based testing framework, which you should use
78
- too. Functional tests are an integral ingredient of highly-quality,
79
- maintainable commands. Behat is a great choice as a testing framework
80
- because:
78
+ too. This command generates all of the files you need. Functional tests
79
+ are an integral ingredient of highly-quality, maintainable commands.
80
+ Behat is a great choice as a testing framework because:
81
81
82
82
* It’s easy to write new tests, which means they’ll actually get written.
83
83
* The tests interface with your command in the same manner as your users
@@ -106,8 +106,16 @@ Functional tests typically follow this pattern:
106
106
* ** When** a user performs a specific action,
107
107
* ** Then** the end result should be X (and Y and Z).
108
108
109
- This command generates all of the files needed for you to write Behat
110
- tests for your own command. Specifically:
109
+ View all defined Behat steps available for use with ` behat -dl ` :
110
+
111
+ ```
112
+ Given /^an empty directory$/
113
+ Given /^an empty cache/
114
+ Given /^an? ([^\s]+) file:$/
115
+ Given /^"([^"]+)" replaced with "([^"]+)" in the ([^\s]+) file$/
116
+ ```
117
+
118
+ The files generated by this command include:
111
119
112
120
* ` .travis.yml ` is the configuration file for Travis CI.
113
121
* ` bin/install-package-tests.sh ` will configure your environment to run
0 commit comments