File tree Expand file tree Collapse file tree 1 file changed +10
-0
lines changed
plugins/optimization-detective/tests/storage Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -396,6 +396,16 @@ static function ( $data ) {
396
396
$ user_id = self ::factory ()->user ->create ();
397
397
$ this ->assertIsInt ( $ user_id );
398
398
$ post_ids = self ::factory ()->post ->create_many ( 3 , array ( 'post_author ' => $ user_id ) );
399
+
400
+ // This is a workaround because the author URL pretty permalink is failing for some reason only on GHA.
401
+ add_filter (
402
+ 'author_link ' ,
403
+ static function ( $ link , $ author_id ) {
404
+ return add_query_arg ( 'author ' , $ author_id , home_url ( '/ ' ) );
405
+ },
406
+ 10 ,
407
+ 2
408
+ );
399
409
$ this ->go_to ( get_author_posts_url ( $ user_id ) );
400
410
$ GLOBALS ['template ' ] = trailingslashit ( get_template_directory () ) . 'author.php ' ;
401
411
You can’t perform that action at this time.
0 commit comments