Changeset 7901 for trunk/tests/testcases/activity/functions.php
- Timestamp:
- 02/16/2014 11:51:32 PM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/testcases/activity/functions.php
r7887 r7901 298 298 bp_activity_add_meta( $a, 'foo', 'baz' ); 299 299 $this->assertSame( array( 'bar', 'baz' ), bp_activity_get_meta( $a, 'foo', false ) ); 300 } 301 302 /** 303 * @group activitymeta 304 * @group bp_activity_get_meta 305 * @group cache 306 */ 307 public function test_bp_activity_get_meta_cache_all_on_get() { 308 $a = $this->factory->activity->create(); 309 bp_activity_add_meta( $a, 'foo', 'bar' ); 310 bp_activity_add_meta( $a, 'foo1', 'baz' ); 311 $this->assertFalse( wp_cache_get( $a, 'activity_meta' ) ); 312 313 // A single query should prime the whole meta cache 314 bp_activity_get_meta( $a, 'foo' ); 315 316 $c = wp_cache_get( $a, 'activity_meta' ); 317 $this->assertNotEmpty( $c['foo1'] ); 300 318 } 301 319
Note: See TracChangeset
for help on using the changeset viewer.