Page MenuHomePhabricator

Get rid of wgEchoConfig hack for qunit tests
Closed, ResolvedPublic

Description

https://github.com/wikimedia/mediawiki-extensions-Echo/blob/5a290dd1a28d383692d8665072f32d8bf2cf80a1/Hooks.php#L1133-L1153

extensions/Echo/Hooks.php
		// Provide info for the Overlay

		if ( $user->isLoggedIn() ) {
			$vars['wgEchoConfig'] = $wgEchoConfig;
		} elseif (
			$outputPage->getTitle()->equals( SpecialPage::getTitleFor( 'JavaScriptTest', 'qunit' ) ) ||
			// Also if running from /plain or /export
			$outputPage->getTitle()->isSubpageOf( SpecialPage::getTitleFor( 'JavaScriptTest', 'qunit' ) )
		) {
			// For testing purposes
			$vars['wgEchoConfig'] = array(
				'eventlogging' => array(
					'EchoInteraction' => array(),
				),
			);
		}

We should not need to do this on the PHP side.

Event Timeline

Legoktm raised the priority of this task from to Needs Triage.
Legoktm updated the task description. (Show Details)
Legoktm added subscribers: Legoktm, Mooeypoo.
Restricted Application added subscribers: StudiesWorld, Aklapper. · View Herald Transcript
Krinkle subscribed.

(For the record, still there anno 2017)

Change 448101 had a related patch set uploaded (by Legoktm; owner: Legoktm):
[mediawiki/extensions/Echo@master] Remove $wgEchoEventLoggingSchemas qunit hack

https://gerrit.wikimedia.org/r/448101

Change 448101 merged by jenkins-bot:
[mediawiki/extensions/Echo@master] Remove $wgEchoEventLoggingSchemas qunit hack

https://gerrit.wikimedia.org/r/448101

Krinkle assigned this task to Legoktm.
Krinkle removed a project: Patch-For-Review.