From: C. Scott Ananian Date: Tue, 25 Sep 2018 14:21:24 +0000 (-0400) Subject: OutputPageTest: Don't rely on side effects of previous tests X-Git-Tag: 1.34.0-rc.0~3992^2~1 X-Git-Url: http://git.cyclocoop.org/%7B%24www_url%7Dadmin/membres/fiche.php?a=commitdiff_plain;h=775bcac17220296e5d10d10178139a5884a4c7f2;p=lhc%2Fweb%2Fwiklou.git OutputPageTest: Don't rely on side effects of previous tests Use the proper `MediaWikiTextCase::hideDeprecated()` method. Bug: T191960 Change-Id: I974618a0bd1e11434d167820d119dcfd6e47b092 --- diff --git a/tests/phpunit/includes/OutputPageTest.php b/tests/phpunit/includes/OutputPageTest.php index d334b73925..e7b7c76cf6 100644 --- a/tests/phpunit/includes/OutputPageTest.php +++ b/tests/phpunit/includes/OutputPageTest.php @@ -174,11 +174,12 @@ class OutputPageTest extends MediaWikiTestCase { /** * Test the actual behavior of the method (in the case where it doesn't throw, e.g., in - * production). Since it threw an exception once in this file, it won't when we call it again. + * production). * * @covers OutputPage::addScriptFile */ public function testAddDeprecatedScriptFileNoOp() { + $this->hideDeprecated( 'OutputPage::addScriptFile' ); $op = $this->newInstance(); $op->addScriptFile( 'ignored-script.js' );