mediawiki-extensions-Popups/tests/qunit
joakin 557fd113c8 Hygiene: Use factory functions instead of classes
Instead of using constructor functions, use factory functions to
generate the gateway objects, because of:

* Consistency on the approach in the repository, no constructor
  functions are used, the factory function pattern prevales.
* Real private data with closures
* No use of `this`, which is dynamic and unbound in JS and a source of
  errors. In contrast, by using a factory function, the
  function/methods-of-the-object are tightly bound to the internal data.

Additional changes:
* Specify more the type of createRESTBaseGateway's parameter to improve
clarity on the intent of the parameter
  * From: @param {jQuery} api
  * To:   @param {Function} ajax function from jQuery for example

Supporting documentation:
* https://medium.com/javascript-scene/javascript-factory-functions-vs-constructor-functions-vs-classes-2f22ceddf33e

Change-Id: Iacbb098b646843a01f459b15343057e2e4851d35
2017-02-08 18:28:21 +01:00
..
ext.popups Hygiene: Use factory functions instead of classes 2017-02-08 18:28:21 +01:00
ext.popups.core.test.js Add LINK_DWELL and LINK_ABANDON actions 2016-11-10 11:47:55 +00:00
ext.popups.desktopRenderer.test.js Directory structure should reflect the ResourceLoader definitions 2016-10-19 20:52:40 +00:00
ext.popups.renderer.article.test.js Remove optional survey link 2016-11-09 14:41:03 +00:00
ext.popups.schemaPopups.utils.test.js Hygiene: Rename getMassagedData to processHovercardEvent 2016-10-31 11:25:09 +00:00