Make WordPress Core


Ignore:
Timestamp:
08/08/2022 11:33:11 PM (3 years ago)
Author:
azaozz
Message:

Build/Test Tools: Add @covers tags to the options tests.

Props pbearne, jrf, hellofromTonya, patopaiar, ironprogrammer, antonvlasenko, SergeyBiryukov, costdev.
See #39265.

File:
1 edited

Legend:

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

    r53494 r53865  
    1212    class Tests_Option_Multisite extends WP_UnitTestCase {
    1313
     14        /**
     15         * @covers ::get_blog_option
     16         * @covers ::get_option
     17         * @covers ::add_blog_option
     18         * @covers ::update_blog_option
     19         * @covers ::delete_blog_option
     20         */
    1421        public function test_from_same_site() {
    1522            $key    = __FUNCTION__ . '_1';
     
    4956        }
    5057
     58        /**
     59         * @covers ::get_blog_option
     60         * @covers ::get_option
     61         * @covers ::add_blog_option
     62         * @covers ::update_blog_option
     63         * @covers ::delete_blog_option
     64         */
    5165        public function test_from_same_site_with_null_blog_id() {
    5266            $key    = __FUNCTION__ . '_1';
     
    8599        }
    86100
     101        /**
     102         * @covers ::get_blog_option
     103         * @covers ::get_option
     104         * @covers ::add_blog_option
     105         * @covers ::update_blog_option
     106         * @covers ::delete_blog_option
     107         */
    87108        public function test_with_another_site() {
    88109            $user_id = self::factory()->user->create();
     
    134155        /**
    135156         * @group multisite
     157         *
     158         * @covers ::get_site_option
    136159         */
    137160        public function test_site_notoptions() {
     
    152175        }
    153176
     177        /**
     178         * @covers ::users_can_register_signup_filter
     179         * @covers ::get_site_option
     180         */
    154181        public function test_users_can_register_signup_filter() {
    155182
    156             $registration = get_site_option( 'registration' );
     183            get_site_option( 'registration' );
    157184            $this->assertFalse( users_can_register_signup_filter() );
    158185
     
    169196        /**
    170197         * @dataProvider data_illegal_names
     198         *
     199         * @covers ::update_site_option
     200         * @covers ::get_site_option
    171201         */
    172202        public function test_sanitize_network_option_illegal_names( $option_value, $sanitized_option_value ) {
     
    188218         * @param $option_value
    189219         * @param $sanitized_option_value
     220         *
     221         * @covers ::update_site_option
     222         * @covers ::get_site_option
    190223         */
    191224        public function test_sanitize_network_option_limited_email_domains( $option_value, $sanitized_option_value ) {
     
    199232         * @param $option_value
    200233         * @param $sanitized_option_value
     234         *
     235         * @covers ::update_site_option
     236         * @covers ::get_site_option
    201237         */
    202238        public function test_sanitize_network_option_banned_email_domains( $option_value, $sanitized_option_value ) {
Note: See TracChangeset for help on using the changeset viewer.