aboutsummaryrefslogtreecommitdiffstats
path: root/tests/lib/AppFramework/Http/DataResponseTest.php
diff options
context:
space:
mode:
authorChristoph Wurst <christoph@winzerhof-wurst.at>2020-03-26 09:30:18 +0100
committerChristoph Wurst <christoph@winzerhof-wurst.at>2020-03-26 16:34:56 +0100
commitb80ebc96748b45fd2e0ba9323308657c4b00b7ec (patch)
treeec20e0ffa2f86b9b54939a83a785407319f94559 /tests/lib/AppFramework/Http/DataResponseTest.php
parent62403d0932be7d620c7bdadc6b4e13eb496fcd6f (diff)
downloadnextcloud-server-b80ebc96748b45fd2e0ba9323308657c4b00b7ec.tar.gz
nextcloud-server-b80ebc96748b45fd2e0ba9323308657c4b00b7ec.zip
Use the short array syntax, everywhere
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
Diffstat (limited to 'tests/lib/AppFramework/Http/DataResponseTest.php')
-rw-r--r--tests/lib/AppFramework/Http/DataResponseTest.php14
1 files changed, 7 insertions, 7 deletions
diff --git a/tests/lib/AppFramework/Http/DataResponseTest.php b/tests/lib/AppFramework/Http/DataResponseTest.php
index b629c6d385e..7af11807d87 100644
--- a/tests/lib/AppFramework/Http/DataResponseTest.php
+++ b/tests/lib/AppFramework/Http/DataResponseTest.php
@@ -41,15 +41,15 @@ class DataResponseTest extends \Test\TestCase {
public function testSetData() {
- $params = array('hi', 'yo');
+ $params = ['hi', 'yo'];
$this->response->setData($params);
- $this->assertEquals(array('hi', 'yo'), $this->response->getData());
+ $this->assertEquals(['hi', 'yo'], $this->response->getData());
}
public function testConstructorAllowsToSetData() {
- $data = array('hi');
+ $data = ['hi'];
$code = 300;
$response = new DataResponse($data, $code);
@@ -59,9 +59,9 @@ class DataResponseTest extends \Test\TestCase {
public function testConstructorAllowsToSetHeaders() {
- $data = array('hi');
+ $data = ['hi'];
$code = 300;
- $headers = array('test' => 'something');
+ $headers = ['test' => 'something'];
$response = new DataResponse($data, $code, $headers);
$expectedHeaders = [
@@ -78,12 +78,12 @@ class DataResponseTest extends \Test\TestCase {
public function testChainability() {
- $params = array('hi', 'yo');
+ $params = ['hi', 'yo'];
$this->response->setData($params)
->setStatus(Http::STATUS_NOT_FOUND);
$this->assertEquals(Http::STATUS_NOT_FOUND, $this->response->getStatus());
- $this->assertEquals(array('hi', 'yo'), $this->response->getData());
+ $this->assertEquals(['hi', 'yo'], $this->response->getData());
}