Skip to content

Commit

Permalink
Load the plugin functions during simulation
Browse files Browse the repository at this point in the history
Fixes #15
  • Loading branch information
JDGrimes authored Jan 17, 2017
1 parent c7f4c33 commit 2574c5a
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/bin/simulate-plugin-use.php
Original file line number Diff line number Diff line change
@@ -39,6 +39,15 @@
*/
require $simulation_file;

/**
* Load the WordPress plugin functions.
*
* These are usually only loaded in the admin, so we need to load them manually here.
*
* @since 0.2.3
*/
require_once ABSPATH . '/wp-admin/includes/plugin.php';

// Deactivate the plugin.
deactivate_plugins( $plugin_file, false, $network_wide );

0 comments on commit 2574c5a

Please sign in to comment.