mediawiki-extensions-Echo/tests/phpunit
Michael Holloway a3674974f1 Add push subscription management
Adds DB tables for storing push subscriptions, some DB interaction code
for retrieving them within MediaWiki, and a set of API modules for
managing them from the outside world.

When testing this patch, be sure to run maintenance/update.php to create
the new tables, and set $wgEchoEnablePush = true in LocalSettings.php
to enable the API new API module.

N.B. The current DB schema is centered on app push subscriptions. Web
push subscriptions require slightly different handling, since they are
provided by browsers as a JSON blob rather than a token string. How to
handle web push subscriptions is a question we can defer until the time
comes to add web push support.

Subscription data is stored in the echo_push_subscription table, with
provider names normalized into the echo_push_provider table. We expect to
be looking up subscriptions by central user ID, so that column is indexed.
The subscription data also includes a column to store SHA256 digests of
the subscriber tokens. This is for use as a unique key constraint, since
we expect every push token to be univerally unique, and the token values
themselves may be too large to reasonably index in MySQL.

Bug: T252899
Change-Id: I3928761b3fba12e54ff4850e9a05c68ec7772f62
2020-06-02 13:40:00 -04:00
..
api Add push subscription management 2020-06-02 13:40:00 -04:00
cache Merge "Use absolute class names in @covers tags" 2019-10-24 18:37:15 +00:00
controller Use absolute class names in @covers tags 2019-10-23 12:23:09 +02:00
formatters Use absolute class names in @covers tags 2019-10-23 12:23:09 +02:00
integration Add push subscription management 2020-06-02 13:40:00 -04:00
maintenance Merge "Use absolute class names in @covers tags" 2019-10-24 18:37:15 +00:00
mapper Remove hack for PHPUnit's Stub interface 2020-01-23 12:34:48 +00:00
model Use absolute class names in @covers tags 2019-10-23 12:23:09 +02:00
revision_txt Ping users mentioned in edit summaries 2018-02-22 12:37:35 -08:00
unit Add push subscription management 2020-06-02 13:40:00 -04:00
AttributeManagerTest.php build: Updating mediawiki/mediawiki-codesniffer to 29.0.0 2020-01-14 05:09:44 +00:00
ContainmentSetTest.php Use absolute class names in @covers tags 2019-10-23 12:23:09 +02:00
DiscussionParserTest.php tests: Avoid calling Title::__construct 2020-03-14 18:41:08 +00:00
EchoDbFactoryTest.php Use absolute class names in @covers tags 2019-10-23 12:23:09 +02:00
EchoHooksTest.php Don't override checkmatrix defaults set elsewhere 2018-09-20 17:15:09 -07:00
EchoSummaryParserTest.php Stop using PHPUnit deprecated methods 2020-01-14 15:59:46 +00:00
NotificationsTest.php Use absolute class names in @covers tags 2019-10-23 12:23:09 +02:00
NotificationStructureTest.php Add a test to validate $wgEchoNotifications 2018-10-10 19:07:04 -07:00
NotifUserTest.php Use absolute class names in @covers tags 2019-10-23 12:23:09 +02:00
TalkPageFunctionalTest.php Add support for watchlist events 2019-12-11 16:39:02 -05:00
ThankYouEditTest.php Prefer strict assertSame() for all numeric assertions 2019-10-23 12:28:30 +02:00
UserLocatorTest.php Merge "Use absolute class names in @covers tags" 2019-10-24 18:37:15 +00:00