From eb40f111d6e192591acf32bba230e76dc7f84271 Mon Sep 17 00:00:00 2001 From: "C. Scott Ananian" Date: Mon, 24 Sep 2018 17:16:10 -0400 Subject: [PATCH] Suppress deprecation warnings for b/c use of UsageException::getMessageArray() Follow up to efaaa2c1d61964dffcd8427cf52568020f9067ea (which was a follow up to Iae0e2ce3). These are exposed when T191960 is fixed. Change-Id: I7c517b5a7cccfe9c324d0a9eeb7d774aa1be8adb --- tests/phpunit/includes/api/ApiErrorFormatterTest.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tests/phpunit/includes/api/ApiErrorFormatterTest.php b/tests/phpunit/includes/api/ApiErrorFormatterTest.php index aa579ab014..f36faf7fed 100644 --- a/tests/phpunit/includes/api/ApiErrorFormatterTest.php +++ b/tests/phpunit/includes/api/ApiErrorFormatterTest.php @@ -555,6 +555,10 @@ class ApiErrorFormatterTest extends MediaWikiLangTestCase { * @param array $expect */ public function testGetMessageFromException_BC( $exception, $options, $expect ) { + if ( $exception instanceof UsageException ) { + $this->hideDeprecated( 'UsageException::getMessageArray' ); + } + $result = new ApiResult( 8388608 ); $formatter = new ApiErrorFormatter_BackCompat( $result ); -- 2.20.1