mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/ConfirmEdit
synced 2024-12-18 02:41:01 +00:00
a0feac27b0
Change-Id: I2933639f9cb50db2101c4765ce9d8f9069d253b8
34 lines
983 B
PHP
34 lines
983 B
PHP
<?php
|
|
|
|
use MediaWiki\Auth\AuthenticationRequestTestCase;
|
|
use MediaWiki\Extension\ConfirmEdit\ReCaptchaNoCaptcha\ReCaptchaNoCaptchaAuthenticationRequest;
|
|
|
|
/**
|
|
* @covers \MediaWiki\Extension\ConfirmEdit\ReCaptchaNoCaptcha\ReCaptchaNoCaptchaAuthenticationRequest
|
|
*/
|
|
class ReCaptchaNoCaptchaAuthenticationRequestTest extends AuthenticationRequestTestCase {
|
|
|
|
public function setUp(): void {
|
|
parent::setUp();
|
|
|
|
$this->mergeMwGlobalArrayValue(
|
|
'wgAutoloadClasses',
|
|
[
|
|
'MediaWiki\\Extension\\ConfirmEdit\\ReCaptchaNoCaptcha\\ReCaptchaNoCaptchaAuthenticationRequest'
|
|
=> __DIR__ . '/../../ReCaptchaNoCaptcha/includes/ReCaptchaNoCaptchaAuthenticationRequest.php'
|
|
]
|
|
);
|
|
}
|
|
|
|
protected function getInstance( array $args = [] ) {
|
|
return new ReCaptchaNoCaptchaAuthenticationRequest();
|
|
}
|
|
|
|
public function provideLoadFromSubmission() {
|
|
return [
|
|
'no proof' => [ [], [], false ],
|
|
'normal' => [ [], [ 'captchaWord' => 'abc' ], [ 'captchaWord' => 'abc' ] ],
|
|
];
|
|
}
|
|
}
|