| @@ 87-94 (lines=8) @@ | ||
| 84 | * @test |
|
| 85 | * @covers ::__construct |
|
| 86 | */ |
|
| 87 | public function settingValidPropertyThrowsAnException() |
|
| 88 | { |
|
| 89 | $this->expectException(ReadOnlyViolationException::class); |
|
| 90 | $this->expectExceptionMessage("Property 'success' is read-only"); |
|
| 91 | ||
| 92 | $response = new FilterResponse([]); |
|
| 93 | $response->success = false; |
|
| 94 | } |
|
| 95 | ||
| 96 | /** |
|
| 97 | * @test |
|
| @@ 100-107 (lines=8) @@ | ||
| 97 | * @test |
|
| 98 | * @covers ::__construct |
|
| 99 | */ |
|
| 100 | public function settingInvalidPropertyThrowsAnException() |
|
| 101 | { |
|
| 102 | $this->expectException(InvalidArgumentException::class); |
|
| 103 | $this->expectExceptionMessage("Property 'foo' does not exist"); |
|
| 104 | ||
| 105 | $response = new FilterResponse([]); |
|
| 106 | $response->foo = false; |
|
| 107 | } |
|
| 108 | ||
| 109 | /** |
|
| 110 | * @test |
|