Make WordPress Core

Changeset 30559


Ignore:
Timestamp:
11/25/2014 04:02:26 AM (12 years ago)
Author:
jeremyfelt
Message:

Add basic unit tests for is_plugin_active_for_network()

Props rodrigosprimo
Fixes #30491

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/tests/multisite/network.php

    r29916 r30559  
    134134        }
    135135
     136        function test_is_plugin_active_for_network_true() {
     137                activate_plugin( 'hello.php', '', true );
     138                $this->assertTrue( is_plugin_active_for_network( 'hello.php' ) );
     139        }
     140
     141        function test_is_plugin_active_for_network_false() {
     142                deactivate_plugins( 'hello.php', false, true );
     143                $this->assertFalse( is_plugin_active_for_network( 'hello.php' ) );
     144        }
     145
    136146        function _helper_deactivate_hook() {
    137147                $this->plugin_hook_count++;
Note: See TracChangeset for help on using the changeset viewer.