WordPress.org

Make WordPress Core


Ignore:
Timestamp:
04/22/2017 06:58:46 PM (2 years ago)
Author:
johnbillion
Message:

Build/Test Tools: Introduce ms-required and ms-excluded groups for tests.

Tests in the ms-excluded group are now excluded when running tests with multisite enabled, and tests in the ms-required group are excluded when running tests without multisite enabled. The end result is a significantly reduced number of skipped tests polluting PHPUnit's output, which means verbose mode can be used to more easily see which tests are skipped or incomplete, and why.

See #40531

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/tests/user/query.php

    r39915 r40520  
    552552    }
    553553
     554    /**
     555     * @group ms-required
     556     */
    554557    public function test_roles_and_caps_should_be_populated_for_explicit_value_of_blog_id_on_nonms() {
    555558        if ( is_multisite() ) {
     
    570573    }
    571574
     575    /**
     576     * @group ms-required
     577     */
    572578    public function test_roles_and_caps_should_be_populated_for_explicit_value_of_current_blog_id_on_ms() {
    573579        if ( ! is_multisite() ) {
     
    588594    }
    589595
     596    /**
     597     * @group ms-required
     598     */
    590599    public function test_roles_and_caps_should_be_populated_for_explicit_value_of_different_blog_id_on_ms_when_fields_all_with_meta() {
    591600        if ( ! is_multisite() ) {
     
    613622    /**
    614623     * @ticket 31878
     624     * @group ms-required
    615625     */
    616626    public function test_roles_and_caps_should_be_populated_for_explicit_value_of_different_blog_id_on_ms_when_fields_all() {
     
    638648    /**
    639649     * @ticket 32019
     650     * @group ms-required
    640651     */
    641652    public function test_who_authors() {
     
    664675    /**
    665676     * @ticket 32019
     677     * @group ms-required
    666678     */
    667679    public function test_who_authors_should_work_alongside_meta_query() {
     
    699711    /**
    700712     * @ticket 36724
     713     * @group ms-required
    701714     */
    702715    public function test_who_authors_should_work_alongside_meta_params() {
     
    792805    /**
    793806     * @ticket 32250
     807     * @group ms-required
    794808     */
    795809    public function test_has_published_posts_should_respect_blog_id() {
     
    13591373    /**
    13601374     * @ticket 22212
     1375     * @group ms-required
    13611376     */
    13621377    public function test_blog_id_should_restrict_by_blog_without_requiring_a_named_role() {
     
    13811396     * @ticket 22212
    13821397     * @ticket 21119
     1398     * @group ms-required
    13831399     */
    13841400    public function test_calling_prepare_query_a_second_time_should_not_add_another_cap_query_on_multisite() {
Note: See TracChangeset for help on using the changeset viewer.