Ticket #28486: 28486.2.diff
| File 28486.2.diff, 1.1 KB (added by , 11 years ago) |
|---|
-
tests/phpunit/includes/testcase.php
245 245 } 246 246 } 247 247 248 function setExpectedDeprecated( $deprecated_element ) { 249 array_push( $this->expected_deprecated, $deprecated_element ); 250 } 251 252 function setExpectedIncorrectUsage( $doing_it_wrong ) { 253 array_push( $this->expected_doing_it_wrong, $doing_it_wrong ); 254 } 255 248 256 function deprecated_function_run( $function ) { 249 257 if ( ! in_array( $function, $this->caught_deprecated ) ) 250 258 $this->caught_deprecated[] = $function; -
tests/phpunit/tests/includes/helpers.php
168 168 169 169 $this->assertFalse( isset( $stati['foo'] ) ); 170 170 } 171 172 public function test_setExpectedDeprecated() { 173 _deprecated_function( __FUNCTION__, '2.5' ); 174 $this->setExpectedDeprecated( 'test_setExpectedDeprecated' ); 175 } 171 176 }