Per wikitech-l consensus: https://lists.wikimedia.org/pipermail/wikitech-l/2016-February/084821.html Notes: * Disabled CallTimePassByReference due to false positives (T127163) Change-Id: I2c8ce713ce6600a0bb7bf67537c87044c7a45c4b
31 lines
478 B
PHP
31 lines
478 B
PHP
<?php
|
|
|
|
/**
|
|
* @group API
|
|
* @group Database
|
|
* @group medium
|
|
*
|
|
* @covers ApiUnblock
|
|
*/
|
|
class ApiUnblockTest extends ApiTestCase {
|
|
protected function setUp() {
|
|
parent::setUp();
|
|
$this->doLogin();
|
|
}
|
|
|
|
/**
|
|
* @expectedException UsageException
|
|
*/
|
|
public function testWithNoToken() {
|
|
$this->doApiRequest(
|
|
[
|
|
'action' => 'unblock',
|
|
'user' => 'UTApiBlockee',
|
|
'reason' => 'Some reason',
|
|
],
|
|
null,
|
|
false,
|
|
self::$users['sysop']->getUser()
|
|
);
|
|
}
|
|
}
|