Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion features/plugin-activate.feature
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ Feature: Activate WordPress plugins
*/
"""
And I run `wp plugin deactivate --all`
And I run `php -r 'echo PHP_VERSION;'`
And I run `wp cli info | grep "PHP version" | awk '{print $3}'`
And save STDOUT as {PHP_VERSION}

When I try `wp plugin activate high-requirements`
Expand All @@ -129,6 +129,10 @@ Feature: Activate WordPress plugins
"""
1 out of 1
"""
And STDOUT should not contain:
"""
Success:
"""

Scenario: Adding --exclude with plugin activate --all should exclude the plugins specified via --exclude
When I try `wp plugin activate --all --exclude=hello`
Expand Down
1 change: 1 addition & 0 deletions src/Plugin_Command.php
Original file line number Diff line number Diff line change
Expand Up @@ -368,6 +368,7 @@ public function activate( $args, $assoc_args = array() ) {
$message = wp_strip_all_tags( $message );
$message = str_replace( 'Error: ', '', $message );
WP_CLI::warning( "Failed to activate plugin. {$message}" );
++$errors;
} else {
$this->active_output( $plugin->name, $plugin->file, $network_wide, 'activate' );
++$successes;
Expand Down