Skip to content

Commit e98cb88

Browse files
committed
updated tests
1 parent 95fba19 commit e98cb88

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
"zendframework/zend-diactoros": "^1.3",
2828
"friendsofphp/php-cs-fixer": "^1.12",
2929
"squizlabs/php_codesniffer": "^2.7",
30-
"middlewares/utils": "~0.6"
30+
"middlewares/utils": "~0.7"
3131
},
3232
"autoload": {
3333
"psr-4": {

tests/GeolocationTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,12 @@ public function testGeolocation()
1212
{
1313
$request = Factory::createServerRequest(['REMOTE_ADDR' => '123.9.34.23']);
1414

15-
$response = (new Dispatcher([
15+
$response = Dispatcher::run([
1616
new Geolocation(),
1717
function ($request) {
1818
echo $request->getAttribute('client-location')->first()->getCountry();
1919
},
20-
]))->dispatch($request);
20+
], $request);
2121

2222
$this->assertInstanceOf('Psr\\Http\\Message\\ResponseInterface', $response);
2323
$this->assertEquals('China', (string) $response->getBody());

0 commit comments

Comments
 (0)