We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
TestCase::iniSet()
MockBuilder
1 parent 2e0ac88 commit 3cf05e7Copy full SHA for 3cf05e7
Tests/Loader/ObjectLoaderTest.php
@@ -81,9 +81,8 @@ public function testExceptionOnBadMethod()
81
public function testExceptionOnMethodNotReturningCollection()
82
{
83
$this->expectException(\LogicException::class);
84
- $service = $this->getMockBuilder(\stdClass::class)
85
- ->addMethods(['loadRoutes'])
86
- ->getMock();
+
+ $service = $this->createMock(CustomRouteLoader::class);
87
$service->expects($this->once())
88
->method('loadRoutes')
89
->willReturn('NOT_A_COLLECTION');
@@ -109,6 +108,11 @@ protected function getObject(string $id): object
109
108
}
110
111
+interface CustomRouteLoader
112
+{
113
+ public function loadRoutes();
114
+}
115
116
class TestObjectLoaderRouteService
117
118
private $collection;
0 commit comments