Skip to content

Commit d517708

Browse files
committed
Ensure no themes interfere with forced update test
1 parent 130b61d commit d517708

File tree

1 file changed

+25
-8
lines changed

1 file changed

+25
-8
lines changed

features/theme.feature

Lines changed: 25 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,13 @@ Feature: Manage WordPress themes
8585
When I run `wp theme activate p2`
8686
Then STDOUT should not be empty
8787

88+
# Ensure no other themes interfere with update.
89+
When I run `wp theme list --status=inactive --field=name | xargs wp theme delete`
90+
Then STDOUT should contain:
91+
"""
92+
Success: Deleted
93+
"""
94+
8895
When I run `wp theme install p2 --version=1.4.1 --force`
8996
Then STDOUT should not be empty
9097

@@ -120,19 +127,29 @@ Feature: Manage WordPress themes
120127

121128
When I run `wp theme install p2 --version=1.4.1 --force`
122129
Then STDOUT should contain:
123-
""""
130+
"""
124131
Downloading install
125-
""""
132+
"""
126133
And STDOUT should contain:
127-
""""
134+
"""
128135
package from https://downloads.wordpress.org/theme/p2.1.4.1.zip...
129-
""""
136+
"""
137+
138+
When I run `wp theme activate p2`
139+
Then STDOUT should not be empty
140+
141+
# Ensure no other themes interfere with update.
142+
When I run `wp theme list --status=inactive --field=name | xargs wp theme delete`
143+
Then STDOUT should contain:
144+
"""
145+
Success: Deleted
146+
"""
130147

131148
When I run `wp theme status p2`
132149
Then STDOUT should contain:
133-
""""
150+
"""
134151
Update available
135-
""""
152+
"""
136153

137154
When I run `wp theme update --all --exclude=p2 | grep 'Skipped'`
138155
Then STDOUT should contain:
@@ -142,9 +159,9 @@ Feature: Manage WordPress themes
142159

143160
When I run `wp theme status p2`
144161
Then STDOUT should contain:
145-
""""
162+
"""
146163
Update available
147-
""""
164+
"""
148165

149166
Scenario: Get the path of an installed theme
150167
Given a WP install

0 commit comments

Comments
 (0)