diff options
author | Daimona Eaytoy <daimona.wiki@gmail.com> | 2023-06-09 17:01:45 +0200 |
---|---|---|
committer | Daimona Eaytoy <daimona.wiki@gmail.com> | 2023-06-09 17:21:12 +0200 |
commit | 4d5cd3a84fe9da5da2c0dff9aa28edf942178902 (patch) | |
tree | 87b534cd8af625161516024cc407e61a71d6a6d3 /tests/phpunit/includes/htmlform/HTMLFormFieldTest.php | |
parent | 60443f2dd8f92986d0f2ff09c4e30d17b881385e (diff) | |
download | mediawikicore-4d5cd3a84fe9da5da2c0dff9aa28edf942178902.tar.gz mediawikicore-4d5cd3a84fe9da5da2c0dff9aa28edf942178902.zip |
Replace deprecated MWException
Bug: T328220
Change-Id: I66be7a6dd752d6b9c254beb65f4eb5ace3c89776
Diffstat (limited to 'tests/phpunit/includes/htmlform/HTMLFormFieldTest.php')
-rw-r--r-- | tests/phpunit/includes/htmlform/HTMLFormFieldTest.php | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/tests/phpunit/includes/htmlform/HTMLFormFieldTest.php b/tests/phpunit/includes/htmlform/HTMLFormFieldTest.php index 907e546be80b..bea3371d4cb1 100644 --- a/tests/phpunit/includes/htmlform/HTMLFormFieldTest.php +++ b/tests/phpunit/includes/htmlform/HTMLFormFieldTest.php @@ -218,7 +218,7 @@ class HTMLFormFieldTest extends PHPUnit\Framework\TestCase { ], 'requestData' => [], 'callback' => null, - 'exception' => [ MWException::class, '/Unknown operation/' ], + 'exception' => [ InvalidArgumentException::class, '/Unknown operation/' ], ]; yield 'Invalid conditional specification (NOT)' => [ 'fieldInfo' => [ @@ -226,7 +226,7 @@ class HTMLFormFieldTest extends PHPUnit\Framework\TestCase { ], 'requestData' => [], 'callback' => null, - 'exception' => [ MWException::class, '/NOT takes exactly one parameter/' ], + 'exception' => [ InvalidArgumentException::class, '/NOT takes exactly one parameter/' ], ]; yield 'Invalid conditional specification (AND/OR/NAND/NOR)' => [ 'fieldInfo' => [ @@ -234,7 +234,7 @@ class HTMLFormFieldTest extends PHPUnit\Framework\TestCase { ], 'requestData' => [], 'callback' => null, - 'exception' => [ MWException::class, '/Expected array, found string/' ], + 'exception' => [ InvalidArgumentException::class, '/Expected array, found string/' ], ]; yield 'Invalid conditional specification (===/!==) 1' => [ 'fieldInfo' => [ @@ -242,7 +242,7 @@ class HTMLFormFieldTest extends PHPUnit\Framework\TestCase { ], 'requestData' => [], 'callback' => null, - 'exception' => [ MWException::class, '/=== takes exactly two parameters/' ], + 'exception' => [ InvalidArgumentException::class, '/=== takes exactly two parameters/' ], ]; yield 'Invalid conditional specification (===/!==) 2' => [ 'fieldInfo' => [ @@ -250,7 +250,7 @@ class HTMLFormFieldTest extends PHPUnit\Framework\TestCase { ], 'requestData' => [], 'callback' => null, - 'exception' => [ MWException::class, '/Parameters for === must be strings/' ], + 'exception' => [ InvalidArgumentException::class, '/Parameters for === must be strings/' ], ]; yield 'Field disabled if "check" field is checked' => [ |