aboutsummaryrefslogtreecommitdiffstats
path: root/tests/phpunit/includes/content/TextContentTest.php
diff options
context:
space:
mode:
Diffstat (limited to 'tests/phpunit/includes/content/TextContentTest.php')
-rw-r--r--tests/phpunit/includes/content/TextContentTest.php6
1 files changed, 1 insertions, 5 deletions
diff --git a/tests/phpunit/includes/content/TextContentTest.php b/tests/phpunit/includes/content/TextContentTest.php
index 382f71a8664e..4fc2d51d03f0 100644
--- a/tests/phpunit/includes/content/TextContentTest.php
+++ b/tests/phpunit/includes/content/TextContentTest.php
@@ -211,15 +211,11 @@ class TextContentTest extends MediaWikiLangTestCase {
* @group Database
*/
public function testIsCountable( $text, $hasLinks, $mode, $expected ) {
- global $wgArticleCountMethod;
-
- $old = $wgArticleCountMethod;
- $wgArticleCountMethod = $mode;
+ $this->setMwGlobals( 'wgArticleCountMethod', $mode );
$content = $this->newContent( $text );
$v = $content->isCountable( $hasLinks, $this->context->getTitle() );
- $wgArticleCountMethod = $old;
$this->assertEquals( $expected, $v, 'isCountable() returned unexpected value ' . var_export( $v, true )
. ' instead of ' . var_export( $expected, true ) . " in mode `$mode` for text \"$text\"" );