Skip to content

Commit f857c91

Browse files
authored
Merge pull request #281 from wp-cli/fix-gherkin-issues
Fix Gherkin lint issues
2 parents e188856 + 98bfb00 commit f857c91

File tree

4 files changed

+7
-9
lines changed

4 files changed

+7
-9
lines changed

features/db-import.feature

+1-2
Original file line numberDiff line numberDiff line change
@@ -79,8 +79,7 @@ Feature: Import a WordPress database
7979

8080
Scenario: Import database with passed-in options
8181
Given a WP install
82-
83-
Given a debug.sql file:
82+
And a debug.sql file:
8483
"""
8584
INSERT INTO `wp_options` (`option_id`, `option_name`, `option_value`, `autoload`) VALUES (999, 'testoption', 'testval', 'yes'),(999, 'testoption', 'testval', 'yes');
8685
"""

features/db-query.feature

+4-4
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ Feature: Query the database with WordPress' MySQL config
3131
"""
3232

3333
When I try `wp db query "SELECT COUNT(ID) FROM wp_posts;" --dbuser=no_such_user`
34-
Then the return code should not be 0
34+
Then the return code should not be 0
3535
And STDERR should contain:
3636
"""
3737
Access denied
@@ -48,7 +48,7 @@ Feature: Query the database with WordPress' MySQL config
4848
"""
4949

5050
When I try `wp db query --defaults "SELECT COUNT(ID) FROM wp_posts;" --dbuser=no_such_user`
51-
Then the return code should not be 0
51+
Then the return code should not be 0
5252
And STDERR should contain:
5353
"""
5454
Access denied
@@ -65,7 +65,7 @@ Feature: Query the database with WordPress' MySQL config
6565
"""
6666

6767
When I try `wp db query --no-defaults "SELECT COUNT(ID) FROM wp_posts;" --dbuser=no_such_user`
68-
Then the return code should not be 0
68+
Then the return code should not be 0
6969
And STDERR should contain:
7070
"""
7171
Access denied
@@ -75,7 +75,7 @@ Feature: Query the database with WordPress' MySQL config
7575
Scenario: MySQL defaults are available as appropriate with --defaults flag
7676
Given a WP install
7777

78-
When I try `wp db query --defaults --debug`
78+
When I try `wp db query --defaults --debug`
7979
Then STDERR should match #Debug \(db\): Running shell command: /usr/bin/env (mysql|mariadb) --no-auto-rehash#
8080

8181
When I try `wp db query --debug`

features/db-search.feature

+1-2
Original file line numberDiff line numberDiff line change
@@ -265,8 +265,7 @@ Feature: Search through the database
265265

266266
When I run `wp db query "CREATE TABLE no_key ( awesome_stuff TEXT );"`
267267
And I run `wp db query "CREATE TABLE no_text ( id int(11) unsigned NOT NULL AUTO_INCREMENT, PRIMARY KEY (id) );"`
268-
269-
When I try `wp db search example.com no_key --all-tables`
268+
And I try `wp db search example.com no_key --all-tables`
270269
Then STDOUT should be empty
271270
And STDERR should be:
272271
"""

features/db-tables.feature

+1-1
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ Feature: List database tables
4444
# See https://core.trac.wordpress.org/ticket/19755
4545

4646
# Leave out wp_blogmeta for old WP compat.
47-
And STDOUT should contain:
47+
Then STDOUT should contain:
4848
"""
4949
wp_blogs
5050
wp_commentmeta

0 commit comments

Comments
 (0)