2016-12-18 02:20:53 +03:00
|
|
|
<?php
|
|
|
|
namespace tests\codeception\api\_pages;
|
|
|
|
|
|
|
|
use yii\codeception\BasePage;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @property \tests\codeception\api\FunctionalTester $actor
|
|
|
|
*/
|
|
|
|
class InternalRoute extends BasePage {
|
|
|
|
|
|
|
|
public function ban($accountId) {
|
|
|
|
$this->route = '/internal/accounts/' . $accountId . '/ban';
|
|
|
|
$this->actor->sendPOST($this->getUrl());
|
|
|
|
}
|
|
|
|
|
2017-01-05 00:57:04 +03:00
|
|
|
public function pardon($accountId) {
|
|
|
|
$this->route = '/internal/accounts/' . $accountId . '/ban';
|
|
|
|
$this->actor->sendDELETE($this->getUrl());
|
|
|
|
}
|
|
|
|
|
2017-04-03 14:54:33 +03:00
|
|
|
public function info(string $param, string $value) {
|
|
|
|
$this->route = '/internal/accounts/info';
|
|
|
|
$this->actor->sendGET($this->getUrl(), [$param => $value]);
|
|
|
|
}
|
|
|
|
|
2016-12-18 02:20:53 +03:00
|
|
|
}
|