mirror of
git://develop.git.wordpress.org/
synced 2025-02-07 08:04:27 +01:00
Tests: Set the current user to Editor in test_utf8mb3_post_saves_with_emoji()
.
This avoids a "Sorry, you are not allowed to edit this post" error further in the test. The test is currently skipped on GitHub Actions, as only runs on older MySQL versions specifically with the `utf8` character set. The user was previously set for all tests in the file in the `set_up()` method, however that is no longer the case, as it was not required for the majority of the tests. It is, however, necessary for the `edit_post()` call in this particular test. Follow-up to [30346], [53785]. See #55652. git-svn-id: https://develop.svn.wordpress.org/trunk@54067 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
37b2a7fb14
commit
b087346757
@ -302,6 +302,8 @@ class Tests_Post extends WP_UnitTestCase {
|
||||
'post_excerpt' => 'foo😐bat',
|
||||
);
|
||||
|
||||
wp_set_current_user( self::$editor_id );
|
||||
|
||||
edit_post( $data );
|
||||
|
||||
$post = get_post( $post_id );
|
||||
|
Loading…
x
Reference in New Issue
Block a user