Changeset 47343 for branches/3.7/tests/phpunit/tests/meta.php
- Timestamp:
- 02/22/2020 12:05:12 PM (6 years ago)
- Location:
- branches/3.7
- Files:
-
- 2 edited
-
. (modified) (1 prop)
-
tests/phpunit/tests/meta.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
branches/3.7
- Property svn:mergeinfo changed
-
branches/3.7/tests/phpunit/tests/meta.php
r25255 r47343 172 172 $this->assertEquals( 2, substr_count( $posts->request, 'CAST(' ) ); 173 173 } 174 175 function test_meta_cache_order_asc() { 176 $post_id = $this->factory->post->create(); 177 $colors = array( 'red', 'blue', 'yellow', 'green' ); 178 foreach ( $colors as $color ) 179 add_post_meta( $post_id, 'color', $color ); 180 181 foreach ( range( 1, 10 ) as $i ) { 182 $meta = get_post_meta( $post_id, 'color' ); 183 $this->assertEquals( $meta, $colors ); 184 185 if ( 0 === $i % 2 ) 186 wp_cache_delete( $post_id, 'post_meta' ); 187 } 188 } 174 189 }
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)