summaryrefslogtreecommitdiff
path: root/tests/Unit/Http
diff options
context:
space:
mode:
Diffstat (limited to 'tests/Unit/Http')
-rw-r--r--tests/Unit/Http/RequestServiceProviderTest.php2
-rw-r--r--tests/Unit/Http/RequestTest.php6
-rw-r--r--tests/Unit/Http/SessionServiceProviderTest.php6
3 files changed, 7 insertions, 7 deletions
diff --git a/tests/Unit/Http/RequestServiceProviderTest.php b/tests/Unit/Http/RequestServiceProviderTest.php
index 0a2ae31d..07dab086 100644
--- a/tests/Unit/Http/RequestServiceProviderTest.php
+++ b/tests/Unit/Http/RequestServiceProviderTest.php
@@ -59,7 +59,7 @@ class RequestServiceProviderTest extends ServiceProviderTest
/** @var ServiceProvider|MockObject $serviceProvider */
$serviceProvider = $this->getMockBuilder(RequestServiceProvider::class)
->setConstructorArgs([$app])
- ->setMethods(['setTrustedProxies'])
+ ->onlyMethods(['setTrustedProxies'])
->getMock();
$serviceProvider->expects($this->once())
->method('setTrustedProxies')
diff --git a/tests/Unit/Http/RequestTest.php b/tests/Unit/Http/RequestTest.php
index 3f52709d..1635f73d 100644
--- a/tests/Unit/Http/RequestTest.php
+++ b/tests/Unit/Http/RequestTest.php
@@ -93,7 +93,7 @@ class RequestTest extends TestCase
/** @var Request|MockObject $request */
$request = $this
->getMockBuilder(Request::class)
- ->setMethods(['getPathInfo'])
+ ->onlyMethods(['getPathInfo'])
->getMock();
$request
@@ -116,7 +116,7 @@ class RequestTest extends TestCase
/** @var Request|MockObject $request */
$request = $this
->getMockBuilder(Request::class)
- ->setMethods(['getUri'])
+ ->onlyMethods(['getUri'])
->getMock();
$request
@@ -139,7 +139,7 @@ class RequestTest extends TestCase
/** @var Request|MockObject $request */
$request = $this
->getMockBuilder(Request::class)
- ->setMethods(['getQueryString', 'path'])
+ ->onlyMethods(['getQueryString', 'path'])
->getMock();
$request->expects($this->exactly(2))
diff --git a/tests/Unit/Http/SessionServiceProviderTest.php b/tests/Unit/Http/SessionServiceProviderTest.php
index 08f1945a..84dfd9d1 100644
--- a/tests/Unit/Http/SessionServiceProviderTest.php
+++ b/tests/Unit/Http/SessionServiceProviderTest.php
@@ -36,7 +36,7 @@ class SessionServiceProviderTest extends ServiceProviderTest
/** @var SessionServiceProvider|MockObject $serviceProvider */
$serviceProvider = $this->getMockBuilder(SessionServiceProvider::class)
->setConstructorArgs([$app])
- ->setMethods(['isCli'])
+ ->onlyMethods(['isCli'])
->getMock();
/** @var Config|MockObject $config */
@@ -175,7 +175,7 @@ class SessionServiceProviderTest extends ServiceProviderTest
$sessionStorage = $this->getMockForAbstractClass(StorageInterface::class);
return $this->getMockBuilder(Session::class)
->setConstructorArgs([$sessionStorage])
- ->setMethods(['start', 'has', 'set'])
+ ->onlyMethods(['start', 'has', 'set'])
->getMock();
}
@@ -185,7 +185,7 @@ class SessionServiceProviderTest extends ServiceProviderTest
private function getRequestMock()
{
return $this->getMockBuilder(Request::class)
- ->setMethods(['setSession'])
+ ->onlyMethods(['setSession'])
->getMock();
}
}