Build/Test Tools: Automatically skip tests in the ms-required and ms-excluded groups.

This removes the need to manually call `$this->skipWithMultisite()` and `$this->skipWithoutMultisite()` from within the test when the test only runs without Multisite or only runs on Multisite, respectively.

Props jdgrimes for the suggestion.

Fixes #40531


git-svn-id: https://develop.svn.wordpress.org/trunk@40564 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
John Blackbourn
2017-05-01 20:34:10 +00:00
parent f72ce6dc6e
commit c759785cea
20 changed files with 11 additions and 152 deletions

View File

@@ -12,8 +12,6 @@ class Tests_User_CountUsers extends WP_UnitTestCase {
* @group ms-excluded
*/
public function test_count_users_is_accurate( $strategy ) {
$this->skipWithMultisite();
// Setup users
$admin = self::factory()->user->create( array(
'role' => 'administrator',
@@ -60,8 +58,6 @@ class Tests_User_CountUsers extends WP_UnitTestCase {
* @dataProvider data_count_users_strategies
*/
public function test_count_users_multisite_is_accurate( $strategy ) {
$this->skipWithoutMultisite();
// Setup users
$admin = self::factory()->user->create( array(
'role' => 'administrator',