Make WordPress Core

Changeset 53159


Ignore:
Timestamp:
04/12/2022 03:59:45 PM (3 years ago)
Author:
joedolson
Message:

Administration: Add unit test for term supplementary notice.

Adds a new test assertion to handle the supplemental data array passed in ajax-response.js.

Follow up to [53123].

Props SergeyBiryukov, peterwilsoncc.
Fixes #55078.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/tests/ajax/AddTag.php

    r52170 r53159  
    3939        }
    4040
     41        // The response message is in the `data` property in WP 5.9.
    4142        $this->assertSame( $expected, (string) $this->get_xml_response_taxonomy()->response_data );
     43        // The response message is in the `supplemental->notice` property in WP 6.0+.
     44        $this->assertSame( $expected, (string) $this->get_xml_response_taxonomy()->supplemental->notice );
    4245    }
    4346
Note: See TracChangeset for help on using the changeset viewer.