diff options
author | daniel <dkinzler@wikimedia.org> | 2025-01-13 22:14:57 +0100 |
---|---|---|
committer | daniel <dkinzler@wikimedia.org> | 2025-02-20 10:45:29 +0100 |
commit | 6c87a4e80f702d4253b48f2b5af809f9f9ed05d9 (patch) | |
tree | 8caea686286f53efe8590867fbc198cc2a1f62c5 /tests/phpunit/includes/api/ApiImportTest.php | |
parent | a39eae9235c1b6c8cd83d56351c24847503ec620 (diff) | |
download | mediawikicore-6c87a4e80f702d4253b48f2b5af809f9f9ed05d9.tar.gz mediawikicore-6c87a4e80f702d4253b48f2b5af809f9f9ed05d9.zip |
PageUpdatedEvent: improve modeling of flags
Why:
- Improve consistency, naming, documentation and definition of flags.
What:
- remove direct access to flags, provide a separate getter for each flag
instead.
- Deprecate EDIT_SUPPRESS_RC in favor of EDIT_SILENT
- Introduce EDIT_IMPLICIT to replace "automated" mode
- Introduce FLAG_RECONCILIATION_REQUEST into PageEvent.
- Introduce isReconciliationRequest into DomainEvent.
Bug: T383552
Change-Id: I2bffbb5810376829f871e1840ca799a8d8232dda
Diffstat (limited to 'tests/phpunit/includes/api/ApiImportTest.php')
-rw-r--r-- | tests/phpunit/includes/api/ApiImportTest.php | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/phpunit/includes/api/ApiImportTest.php b/tests/phpunit/includes/api/ApiImportTest.php index 11b0cecc688c..effc66ed9fe6 100644 --- a/tests/phpunit/includes/api/ApiImportTest.php +++ b/tests/phpunit/includes/api/ApiImportTest.php @@ -53,16 +53,16 @@ class ApiImportTest extends ApiUploadTestCase { ); Assert::assertTrue( $event->isSilent(), 'isSilent' ); - Assert::assertTrue( $event->isAutomated(), 'isAutomated' ); + Assert::assertTrue( $event->isImplicit(), 'isImplicit' ); if ( $calls === 1 ) { // First call, from ImportableOldRevisionImporter - Assert::assertTrue( $event->isNew(), 'isNew' ); + Assert::assertTrue( $event->isCreation(), 'isCreation' ); Assert::assertTrue( $event->isRevisionChange(), 'isRevisionChange' ); Assert::assertTrue( $event->isContentChange(), 'isContentChange' ); } else { // Second call, from ApiImportReporter - Assert::assertFalse( $event->isNew(), 'isNew' ); + Assert::assertFalse( $event->isCreation(), 'isCreation' ); Assert::assertTrue( $event->isRevisionChange(), 'isRevisionChange' ); Assert::assertFalse( $event->isContentChange(), 'isContentChange' ); } |