Make WordPress Core


Ignore:
Timestamp:
11/30/2017 11:09:33 PM (7 years ago)
Author:
pento
Message:

Code is Poetry.
WordPress' code just... wasn't.
This is now dealt with.

Props jrf, pento, netweb, GaryJ, jdgrimes, westonruter, Greg Sherwood from PHPCS, and everyone who's ever contributed to WPCS and PHPCS.
Fixes #41057.

File:
1 edited

Legend:

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

    r38398 r42343  
    1313        $now = time();
    1414        for ( $i = 0; $i <= 22; $i++ ) {
    15             $post_date = date( 'Y-m-d H:i:s', $now - ( 10 * $i ) );
    16             self::$posts[ $i ] = $factory->post->create( array(
    17                 'post_date' => $post_date,
    18             ) );
     15            $post_date         = date( 'Y-m-d H:i:s', $now - ( 10 * $i ) );
     16            self::$posts[ $i ] = $factory->post->create(
     17                array(
     18                    'post_date' => $post_date,
     19                )
     20            );
    1921        }
    2022
     
    2527
    2628    public function test_stickies_should_be_ignored_when_is_home_is_false() {
    27         $q = new WP_Query( array(
    28             'year' => date( 'Y' ),
    29             'fields' => 'ids',
    30             'posts_per_page' => 3,
    31         ) );
     29        $q = new WP_Query(
     30            array(
     31                'year'           => date( 'Y' ),
     32                'fields'         => 'ids',
     33                'posts_per_page' => 3,
     34            )
     35        );
    3236
    3337        $expected = array(
Note: See TracChangeset for help on using the changeset viewer.