|
@@ 567-577 (lines=11) @@
|
| 564 |
|
* @Then /^user "([^"]*)" is disabled$/ |
| 565 |
|
* @param string $user |
| 566 |
|
*/ |
| 567 |
|
public function userIsDisabled($user) { |
| 568 |
|
$fullUrl = $this->baseUrl . "v{$this->apiVersion}.php/cloud/users/$user"; |
| 569 |
|
$client = new Client(); |
| 570 |
|
$options = []; |
| 571 |
|
if ($this->currentUser === 'admin') { |
| 572 |
|
$options['auth'] = $this->adminUser; |
| 573 |
|
} |
| 574 |
|
|
| 575 |
|
$this->response = $client->get($fullUrl, $options); |
| 576 |
|
PHPUnit_Framework_Assert::assertEquals("false", $this->response->xml()->data[0]->enabled); |
| 577 |
|
} |
| 578 |
|
|
| 579 |
|
/** |
| 580 |
|
* @Then /^user "([^"]*)" is enabled$/ |
|
@@ 583-593 (lines=11) @@
|
| 580 |
|
* @Then /^user "([^"]*)" is enabled$/ |
| 581 |
|
* @param string $user |
| 582 |
|
*/ |
| 583 |
|
public function userIsEnabled($user) { |
| 584 |
|
$fullUrl = $this->baseUrl . "v{$this->apiVersion}.php/cloud/users/$user"; |
| 585 |
|
$client = new Client(); |
| 586 |
|
$options = []; |
| 587 |
|
if ($this->currentUser === 'admin') { |
| 588 |
|
$options['auth'] = $this->adminUser; |
| 589 |
|
} |
| 590 |
|
|
| 591 |
|
$this->response = $client->get($fullUrl, $options); |
| 592 |
|
PHPUnit_Framework_Assert::assertEquals("true", $this->response->xml()->data[0]->enabled); |
| 593 |
|
} |
| 594 |
|
|
| 595 |
|
/** |
| 596 |
|
* @Given user :user has a quota of :quota |