| @@ 19-25 (lines=7) @@ | ||
| 16 | /** |
|
| 17 | * @inheritdoc |
|
| 18 | */ |
|
| 19 | public function testListUsers() |
|
| 20 | { |
|
| 21 | $http = $this->http->get('users'); |
|
| 22 | $output = $http->getBody()->getContents(); |
|
| 23 | $this->assertEquals(200, $http->getStatusCode()); |
|
| 24 | $this->assertEquals('list all users', $output); |
|
| 25 | } |
|
| 26 | ||
| 27 | /** |
|
| 28 | * @inheritdoc |
|
| @@ 30-36 (lines=7) @@ | ||
| 27 | /** |
|
| 28 | * @inheritdoc |
|
| 29 | */ |
|
| 30 | public function testUserById() |
|
| 31 | { |
|
| 32 | $http = $this->http->get('users/1'); |
|
| 33 | $output = $http->getBody()->getContents(); |
|
| 34 | $this->assertEquals(200, $http->getStatusCode()); |
|
| 35 | $this->assertEquals('show user by id 1', $output); |
|
| 36 | } |
|
| 37 | ||
| 38 | /** |
|
| 39 | * @inheritdoc |
|
| @@ 41-47 (lines=7) @@ | ||
| 38 | /** |
|
| 39 | * @inheritdoc |
|
| 40 | */ |
|
| 41 | public function testCreateUserView() |
|
| 42 | { |
|
| 43 | $http = $this->http->get('users/create'); |
|
| 44 | $output = $http->getBody()->getContents(); |
|
| 45 | $this->assertEquals(200, $http->getStatusCode()); |
|
| 46 | $this->assertEquals('view create user', $output); |
|
| 47 | } |
|
| 48 | ||
| 49 | /** |
|
| 50 | * @inheritdoc |
|
| @@ 81-87 (lines=7) @@ | ||
| 78 | /** |
|
| 79 | * @inheritdoc |
|
| 80 | */ |
|
| 81 | public function testDeleteUserById() |
|
| 82 | { |
|
| 83 | $http = $this->http->delete('users/1'); |
|
| 84 | $output = $http->getBody()->getContents(); |
|
| 85 | $this->assertEquals(200, $http->getStatusCode()); |
|
| 86 | $this->assertEquals('delete user by id 1', $output); |
|
| 87 | } |
|
| 88 | } |
|