mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/AbuseFilter.git
synced 2024-11-23 21:53:35 +00:00
ConfirmEditHandlerTest: Remove method_exists checks
Why: - These checks are no longer needed, now that Idc47bda has been merged What: - Remove the `method_exists()` checks Change-Id: I6e428df6b6e036146ae4cc57374cde8810d3f5f7
This commit is contained in:
parent
18ed47a687
commit
62629ec3e9
|
@ -42,10 +42,7 @@ class ConfirmEditHandlerTest extends MediaWikiIntegrationTestCase {
|
|||
$this->assertStatusGood( $status, 'The default is to not show a CAPTCHA' );
|
||||
|
||||
$simpleCaptcha = Hooks::getInstance();
|
||||
// FIXME: Remove this method_exists check after Idc47bdae8007da938f31e1c0f33e9be4813f41d7 is merged
|
||||
if ( method_exists( $simpleCaptcha, 'setEditFilterMergedContentHandlerInvoked' ) ) {
|
||||
$simpleCaptcha->setEditFilterMergedContentHandlerInvoked();
|
||||
}
|
||||
$simpleCaptcha->setEditFilterMergedContentHandlerInvoked();
|
||||
$simpleCaptcha->setAction( 'edit' );
|
||||
$captchaConsequence = new CaptchaConsequence( $this->createMock( Parameters::class ) );
|
||||
$captchaConsequence->execute();
|
||||
|
@ -57,13 +54,10 @@ class ConfirmEditHandlerTest extends MediaWikiIntegrationTestCase {
|
|||
$this->createMock( User::class ),
|
||||
false
|
||||
);
|
||||
// FIXME: Remove this method_exists check after Idc47bdae8007da938f31e1c0f33e9be4813f41d7 is merged
|
||||
if ( method_exists( $simpleCaptcha, 'shouldForceShowCaptcha' ) ) {
|
||||
$this->assertStatusError(
|
||||
'captcha-edit-fail',
|
||||
$status,
|
||||
'CaptchaConsequence specifies that a CAPTCHA should be shown'
|
||||
);
|
||||
}
|
||||
$this->assertStatusError(
|
||||
'captcha-edit-fail',
|
||||
$status,
|
||||
'CaptchaConsequence specifies that a CAPTCHA should be shown'
|
||||
);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue