wiki.techinc.nl/tests/phpunit/includes/api
Dreamy Jazz eabb13833f Define ApiQuery::isWriteMode
Why:
* ApiQueryBase subclasses may define a ::isWriteMode override, as
  the API call may need to write to the DB.
** This is the case for the CheckUser extension, where the
   'checkuser' API creates a log entry that allows users to audit
   usage of the API.
* ApiQuery currently does not define a implementation of
  ::isWriteMode, which means that the definitions by any class
  that extends ApiQueryBase currently do nothing.
* ApiQuery::isWriteMode should be defined and work in a similar
  way to ApiQuery::isReadMode, so that subclasses of ApiQueryBase
  can have their definitions of ::isWriteMode respected.

What:
* Define ApiQuery::isWriteMode in a similar way to how ApiQuery
  ::isReadMode is written, but also inspecting the modules that
  are used through the 'list' and 'prop' params.
* Add tests for ApiQuery::isWriteMode.

Bug: T361951
Change-Id: Idf1c8f95df58a861404e0c89507c885ec4554793
2024-04-05 16:56:04 +01:00
..
format tests: Namespace api tests 2024-02-18 15:47:04 +00:00
query Define ApiQuery::isWriteMode 2024-04-05 16:56:04 +01:00
Validator tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiAcquireTempUserNameTest.php Update wgAutoCreateTempUser config defaults 2024-04-03 16:25:47 +00:00
ApiBaseTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiBlockInfoTraitTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiBlockTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiChangeContentModelTest.php Improve rate limit tests 2024-03-12 14:00:07 +11:00
ApiCheckTokenTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiClearHasMsgTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiComparePagesTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiContinuationManagerTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiCreateTempUserTraitTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiCSPReportTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiDeleteTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiDisabledTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiEditPageTest.php Remove IDBAccessObject from being implemented in many classes 2024-02-19 10:50:02 +01:00
ApiEntryPointTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiErrorFormatterTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiFeedRecentChangesTest.php Update help text for 'hideanons' in ApiFeedRecentChanges API 2024-02-22 17:20:28 +00:00
ApiLoginTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiLogoutTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiMainTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiMessageTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiMoveTest.php Improve rate limit tests 2024-03-12 14:00:07 +11:00
ApiOpenSearchTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiOptionsTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiPageSetTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiParseTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiProtectTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiPurgeTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiResultTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiRevisionDeleteTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiRollbackTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiSetNotificationTimestampIntegrationTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiStashEditTest.php Update wgAutoCreateTempUser config defaults 2024-04-03 16:25:47 +00:00
ApiTestCase.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiTestContext.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiUnblockTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiUndeleteTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiUploadTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiUploadTestCase.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiUsageExceptionTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiUserrightsTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
ApiWatchTest.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
generateRandomImages.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
MockApi.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
MockApiQueryBase.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00
RandomImageGenerator.php tests: Namespace api tests 2024-02-18 15:47:04 +00:00