Make WordPress Core


Ignore:
Timestamp:
10/16/2014 05:06:22 AM (12 years ago)
Author:
jeremyfelt
Message:

Split and organize multisite unit tests

  • Move ms.php to multisite.php
  • Create multisite.php under directories option/ and user/ to better match existing structure.
  • Create a multisite/ directory containing bootstrap.php, site.php, and network.php for very multisite specific testing.
  • Add unit test groups ms-site, ms-user, ms-option, ms-network, and ms-bootstrap.

Fixes #29896

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/tests/option/siteOption.php

    r26305 r29916  
    9191                $this->assertFalse( get_site_option( $option ) );
    9292        }
    93 
    94         /**
    95          * @group multisite
    96          */
    97         function test_site_notoptions() {
    98                 if ( ! is_multisite() ) {
    99                         $this->markTestSkipped( 'Should only run in multisite' );
    100                 }
    101 
    102                 global $wpdb;
    103                 $notoptions_key = "{$wpdb->siteid}:notoptions";
    104 
    105                 $_notoptions = wp_cache_get( 'notoptions', 'site-options' );
    106                 $this->assertEmpty( $_notoptions );
    107                 $_notoptions1 = wp_cache_get( $notoptions_key, 'site-options' );
    108                 $this->assertEmpty( $_notoptions1 );
    109 
    110                 get_site_option( 'burrito' );
    111 
    112                 $notoptions = wp_cache_get( 'notoptions', 'site-options' );
    113                 $this->assertEmpty( $notoptions );
    114                 $notoptions1 = wp_cache_get( $notoptions_key, 'site-options' );
    115                 $this->assertNotEmpty( $notoptions1 );
    116         }
    11793}
Note: See TracChangeset for help on using the changeset viewer.