mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Echo
synced 2024-11-23 23:44:53 +00:00
Merge "Explicitly call DeferredUpdates::tryOpportunisticExecute() in ThankYouEditTest"
This commit is contained in:
commit
eff1de4fdf
|
@ -2,6 +2,7 @@
|
||||||
|
|
||||||
namespace MediaWiki\Extension\Notifications\Test;
|
namespace MediaWiki\Extension\Notifications\Test;
|
||||||
|
|
||||||
|
use MediaWiki\Deferred\DeferredUpdates;
|
||||||
use MediaWiki\Extension\Notifications\DbFactory;
|
use MediaWiki\Extension\Notifications\DbFactory;
|
||||||
use MediaWiki\Extension\Notifications\Mapper\NotificationMapper;
|
use MediaWiki\Extension\Notifications\Mapper\NotificationMapper;
|
||||||
use MediaWiki\Title\Title;
|
use MediaWiki\Title\Title;
|
||||||
|
@ -39,6 +40,7 @@ class ThankYouEditTest extends MediaWikiIntegrationTestCase {
|
||||||
|
|
||||||
// action
|
// action
|
||||||
$this->editPage( $title, 'this is my first edit', '', NS_MAIN, $user );
|
$this->editPage( $title, 'this is my first edit', '', NS_MAIN, $user );
|
||||||
|
DeferredUpdates::tryOpportunisticExecute();
|
||||||
|
|
||||||
// assertions
|
// assertions
|
||||||
$notificationMapper = new NotificationMapper();
|
$notificationMapper = new NotificationMapper();
|
||||||
|
@ -67,6 +69,7 @@ class ThankYouEditTest extends MediaWikiIntegrationTestCase {
|
||||||
for ( $i = 0; $i < 12; $i++ ) {
|
for ( $i = 0; $i < 12; $i++ ) {
|
||||||
$this->editPage( $page, "this is edit #$i", '', NS_MAIN, $user );
|
$this->editPage( $page, "this is edit #$i", '', NS_MAIN, $user );
|
||||||
}
|
}
|
||||||
|
DeferredUpdates::tryOpportunisticExecute();
|
||||||
$user->clearInstanceCache();
|
$user->clearInstanceCache();
|
||||||
|
|
||||||
// assertions
|
// assertions
|
||||||
|
|
Loading…
Reference in a new issue