Make WordPress Core

Changeset 54242


Ignore:
Timestamp:
09/20/2022 03:56:45 AM (21 months ago)
Author:
peterwilsoncc
Message:

Posts, Post types: Coding standards fixes following [54234].

Props costdev.
See #36905.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/tests/post/getPageByTitle.php

    r54234 r54242  
    167167        $found = get_page_by_title( 'foo', OBJECT, 'wptests_pt' );
    168168        $this->assertSame( $p2, $found->ID, 'Should find a post with post type wptests_pt.' );
    169         $num_queries ++;
     169        ++$num_queries;
    170170        $this->assertSame( $num_queries, get_num_queries(), 'Should result in another database query.' );
    171171    }
     
    197197        $found = get_page_by_title( 'bar' );
    198198        $this->assertSame( $page, $found->ID, 'Should find a page with the new title.' );
    199         $num_queries++;
     199        ++$num_queries;
    200200        $this->assertSame( $num_queries, get_num_queries(), 'Should result in another database query.' );
    201201    }
     
    224224
    225225        $array_n = get_page_by_title( 'foo', ARRAY_N );
    226         $num_queries++; // Add one database query for loading of post metadata.
     226        ++$num_queries; // Add one database query for loading of post metadata.
    227227        $this->assertIsArray( $array_n, 'Should be numbric array.' );
    228228        $this->assertSame( $page, $array_n[0], 'Should match post id.' );
Note: See TracChangeset for help on using the changeset viewer.