From c242b4351b7446c7c1d029c483ef12f0f1307f5c Mon Sep 17 00:00:00 2001 From: Amir Sarabadani Date: Tue, 3 Jan 2017 19:29:16 +0330 Subject: [PATCH] Proper instantiating of QueryPage special pages in QueryAllSpecialPagesTest Change-Id: If4420067011da756b8a36917f1c35fd2d380dae9 --- tests/phpunit/includes/specials/QueryAllSpecialPagesTest.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/phpunit/includes/specials/QueryAllSpecialPagesTest.php b/tests/phpunit/includes/specials/QueryAllSpecialPagesTest.php index c1083afdbc..7b5120c78a 100644 --- a/tests/phpunit/includes/specials/QueryAllSpecialPagesTest.php +++ b/tests/phpunit/includes/specials/QueryAllSpecialPagesTest.php @@ -36,8 +36,9 @@ class QueryAllSpecialPagesTest extends MediaWikiTestCase { foreach ( QueryPage::getPages() as $page ) { $class = $page[0]; + $name = $page[1]; if ( !in_array( $class, $this->manualTest ) ) { - $this->queryPages[$class] = new $class; + $this->queryPages[$class] = SpecialPageFactory::getPage( $name ); } } } -- 2.20.1