- Timestamp:
- 12/03/2021 11:34:55 AM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/rest-api/wpRestUrlDetailsController.php
r51973 r52311 94 94 95 95 // Disables usage of cache during major of tests. 96 add_filter( 'pre_ transient_' . $this->get_transient_name(), '__return_null' );96 add_filter( 'pre_site_transient_' . $this->get_transient_name(), '__return_null' ); 97 97 } 98 98 … … 342 342 public function test_will_return_from_cache_if_populated() { 343 343 $transient_name = $this->get_transient_name(); 344 remove_filter( "pre_ transient_{$transient_name}", '__return_null' );344 remove_filter( "pre_site_transient_{$transient_name}", '__return_null' ); 345 345 346 346 // Force cache to return a known value as the remote URL http response body. 347 347 add_filter( 348 "pre_ transient_{$transient_name}",348 "pre_site_transient_{$transient_name}", 349 349 static function() { 350 350 return '<html><head><title>This value from cache.</title></head><body></body></html>';
Note: See TracChangeset
for help on using the changeset viewer.