aboutsummaryrefslogtreecommitdiffstats
path: root/tests/lib/AppFramework/Controller/ControllerTest.php
diff options
context:
space:
mode:
Diffstat (limited to 'tests/lib/AppFramework/Controller/ControllerTest.php')
-rw-r--r--tests/lib/AppFramework/Controller/ControllerTest.php12
1 files changed, 6 insertions, 6 deletions
diff --git a/tests/lib/AppFramework/Controller/ControllerTest.php b/tests/lib/AppFramework/Controller/ControllerTest.php
index 23ebe6ec984..675d4b7ccec 100644
--- a/tests/lib/AppFramework/Controller/ControllerTest.php
+++ b/tests/lib/AppFramework/Controller/ControllerTest.php
@@ -41,7 +41,7 @@ class ChildController extends Controller {
public function custom($in) {
$this->registerResponder('json', function ($response) {
- return new JSONResponse(array(strlen($response)));
+ return new JSONResponse([strlen($response)]);
});
return $in;
@@ -103,9 +103,9 @@ class ControllerTest extends \Test\TestCase {
public function testFormat() {
- $response = $this->controller->buildResponse(array('hi'), 'json');
+ $response = $this->controller->buildResponse(['hi'], 'json');
- $this->assertEquals(array('hi'), $response->getData());
+ $this->assertEquals(['hi'], $response->getData());
}
@@ -118,10 +118,10 @@ class ControllerTest extends \Test\TestCase {
'Feature-Policy' => "autoplay 'none';camera 'none';fullscreen 'none';geolocation 'none';microphone 'none';payment 'none'",
];
- $response = $this->controller->customDataResponse(array('hi'));
+ $response = $this->controller->customDataResponse(['hi']);
$response = $this->controller->buildResponse($response, 'json');
- $this->assertEquals(array('hi'), $response->getData());
+ $this->assertEquals(['hi'], $response->getData());
$this->assertEquals(300, $response->getStatus());
$this->assertEquals($expectedHeaders, $response->getHeaders());
}
@@ -131,7 +131,7 @@ class ControllerTest extends \Test\TestCase {
$response = $this->controller->custom('hi');
$response = $this->controller->buildResponse($response, 'json');
- $this->assertEquals(array(2), $response->getData());
+ $this->assertEquals([2], $response->getData());
}