@@ -46,43 +46,43 @@ public static function dataGetUriFromGlobals():array{
4646 ];
4747
4848 return [
49- 'HTTPS request ' => [
49+ 'HTTPS request ' => [
5050 'https://www.example.org/blog/article.php?id=10&user=foo ' ,
5151 $ server ,
5252 ],
53- 'HTTPS request with different on value ' => [
53+ 'HTTPS request with different on value ' => [
5454 'https://www.example.org/blog/article.php?id=10&user=foo ' ,
5555 array_merge ($ server , ['HTTPS ' => '1 ' ]),
5656 ],
57- 'HTTP request ' => [
57+ 'HTTP request ' => [
5858 'http://www.example.org/blog/article.php?id=10&user=foo ' ,
5959 array_merge ($ server , ['HTTPS ' => 'off ' , 'SERVER_PORT ' => '80 ' ]),
6060 ],
61- 'HTTP_HOST missing -> fallback to SERVER_NAME ' => [
61+ 'HTTP_HOST missing -> fallback to SERVER_NAME ' => [
6262 'https://www.example.org/blog/article.php?id=10&user=foo ' ,
6363 array_merge ($ server , ['HTTP_HOST ' => null ]),
6464 ],
6565 'HTTP_HOST and SERVER_NAME missing -> fallback to SERVER_ADDR ' => [
6666 'https://217.112.82.20/blog/article.php?id=10&user=foo ' ,
6767 array_merge ($ server , ['HTTP_HOST ' => null , 'SERVER_NAME ' => null ]),
6868 ],
69- 'No query String ' => [
69+ 'No query String ' => [
7070 'https://www.example.org/blog/article.php ' ,
7171 array_merge ($ server , ['REQUEST_URI ' => '/blog/article.php ' , 'QUERY_STRING ' => '' ]),
7272 ],
73- 'Host header with port ' => [
73+ 'Host header with port ' => [
7474 'https://www.example.org:8324/blog/article.php?id=10&user=foo ' ,
7575 array_merge ($ server , ['HTTP_HOST ' => 'www.example.org:8324 ' ]),
7676 ],
77- 'Different port with SERVER_PORT ' => [
77+ 'Different port with SERVER_PORT ' => [
7878 'https://www.example.org:8324/blog/article.php?id=10&user=foo ' ,
7979 array_merge ($ server , ['SERVER_PORT ' => '8324 ' ]),
8080 ],
81- 'REQUEST_URI missing query string ' => [
81+ 'REQUEST_URI missing query string ' => [
8282 'https://www.example.org/blog/article.php?id=10&user=foo ' ,
8383 array_merge ($ server , ['REQUEST_URI ' => '/blog/article.php ' ]),
8484 ],
85- 'Empty server variable ' => [
85+ 'Empty server variable ' => [
8686 'http://localhost ' ,
8787 ['REQUEST_TIME ' => time (), 'SCRIPT_NAME ' => '/blog/article.php ' ], // phpunit fix
8888 ],
@@ -119,7 +119,7 @@ public function testCreateServerRequestFromGlobals():void{
119119 ];
120120
121121 $ _COOKIE = [
122- 'logged-in ' => 'yes! '
122+ 'logged-in ' => 'yes! ' ,
123123 ];
124124
125125 $ _POST = [
@@ -128,7 +128,7 @@ public function testCreateServerRequestFromGlobals():void{
128128 ];
129129
130130 $ _GET = [
131- 'id ' => 10 ,
131+ 'id ' => 10 ,
132132 'user ' => 'foo ' ,
133133 ];
134134
@@ -139,7 +139,7 @@ public function testCreateServerRequestFromGlobals():void{
139139 'tmp_name ' => __DIR__ .'/uploaded_file.tmp ' ,
140140 'error ' => UPLOAD_ERR_OK ,
141141 'size ' => 123 ,
142- ]
142+ ],
143143 ];
144144
145145 $ server = $ this ->server ->createServerRequestFromGlobals ();
@@ -173,11 +173,11 @@ public function testNormalizeMultipleFiles():void{
173173 $ files = [
174174 'files ' => [
175175 'name ' => ['MyFile1.txt ' , 'MyFile2.gif ' , 'MyFile3.txt ' ],
176- 'type ' => ['text/plain ' ,'image/gif ' ,'text/plain ' , ],
176+ 'type ' => ['text/plain ' ,'image/gif ' ,'text/plain ' ],
177177 'tmp_name ' => [$ tmp , $ tmp , $ tmp ],
178178 'error ' => [UPLOAD_ERR_OK , UPLOAD_ERR_PARTIAL , UPLOAD_ERR_OK ],
179179 'size ' => [123 , 456 , 789 ],
180- ]
180+ ],
181181 ];
182182
183183 /** @var array $normalized */
@@ -213,7 +213,7 @@ public function testNormalizeMultipleFiles():void{
213213 'error ' => UPLOAD_ERR_OK ,
214214 'size ' => 789 ,
215215 ],
216- ]
216+ ],
217217 ];
218218
219219 /** @var array $normalized */
0 commit comments