Changeset 35242 for trunk/tests/phpunit/tests/post/listPages.php
- Timestamp:
- 10/17/2015 06:02:16 PM (11 years ago)
- File:
-
- 1 edited
-
trunk/tests/phpunit/tests/post/listPages.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/post/listPages.php
r35225 r35242 28 28 $wpdb->query( 'TRUNCATE ' . $wpdb->prefix . 'posts' ); 29 29 $pages = array(); 30 self:: $factory->user->create();31 $pages[] = self:: $factory->post->create( array( 'post_type' => 'page', 'post_title' => 'Parent 1' ) );32 $pages[] = self:: $factory->post->create( array( 'post_type' => 'page', 'post_title' => 'Parent 2' ) );33 $pages[] = self:: $factory->post->create( array( 'post_type' => 'page', 'post_title' => 'Parent 3', 'post_author' => '2' ) );30 self::factory()->user->create(); 31 $pages[] = self::factory()->post->create( array( 'post_type' => 'page', 'post_title' => 'Parent 1' ) ); 32 $pages[] = self::factory()->post->create( array( 'post_type' => 'page', 'post_title' => 'Parent 2' ) ); 33 $pages[] = self::factory()->post->create( array( 'post_type' => 'page', 'post_title' => 'Parent 3', 'post_author' => '2' ) ); 34 34 35 35 foreach ( $pages as $page ) { 36 $this->pages[$page] = self:: $factory->post->create( array( 'post_parent' => $page, 'post_type' => 'page', 'post_title' => 'Child 1' ) );37 $this->pages[$page] = self:: $factory->post->create( array( 'post_parent' => $page, 'post_type' => 'page', 'post_title' => 'Child 2' ) );38 $this->pages[$page] = self:: $factory->post->create( array( 'post_parent' => $page, 'post_type' => 'page', 'post_title' => 'Child 3' ) );36 $this->pages[$page] = self::factory()->post->create( array( 'post_parent' => $page, 'post_type' => 'page', 'post_title' => 'Child 1' ) ); 37 $this->pages[$page] = self::factory()->post->create( array( 'post_parent' => $page, 'post_type' => 'page', 'post_title' => 'Child 2' ) ); 38 $this->pages[$page] = self::factory()->post->create( array( 'post_parent' => $page, 'post_type' => 'page', 'post_title' => 'Child 3' ) ); 39 39 } 40 40 }
Note: See TracChangeset
for help on using the changeset viewer.