aboutsummaryrefslogtreecommitdiffstats
path: root/tests/lib/AppFramework/Controller/ControllerTest.php
diff options
context:
space:
mode:
authorJoas Schilling <coding@schilljs.com>2022-02-23 10:40:58 +0100
committerJoas Schilling <coding@schilljs.com>2022-02-23 11:01:58 +0100
commitd078d536835fc75a79b5381a628cefb92ae74886 (patch)
tree65dac66485b3562fa04f8fce4fabcac69a36ce74 /tests/lib/AppFramework/Controller/ControllerTest.php
parentcc6653e45c86e8019846274b04154c96e34632cf (diff)
downloadnextcloud-server-d078d536835fc75a79b5381a628cefb92ae74886.tar.gz
nextcloud-server-d078d536835fc75a79b5381a628cefb92ae74886.zip
Fix tests
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'tests/lib/AppFramework/Controller/ControllerTest.php')
-rw-r--r--tests/lib/AppFramework/Controller/ControllerTest.php12
1 files changed, 5 insertions, 7 deletions
diff --git a/tests/lib/AppFramework/Controller/ControllerTest.php b/tests/lib/AppFramework/Controller/ControllerTest.php
index 1d72482e75d..4d36fcadce1 100644
--- a/tests/lib/AppFramework/Controller/ControllerTest.php
+++ b/tests/lib/AppFramework/Controller/ControllerTest.php
@@ -29,6 +29,8 @@ use OCP\AppFramework\Http\DataResponse;
use OCP\AppFramework\Http\JSONResponse;
use OCP\IConfig;
use OCP\IRequest;
+use OCP\IRequestId;
+use OC\AppFramework\DependencyInjection\DIContainer;
class ChildController extends Controller {
public function __construct($appName, $request) {
@@ -75,15 +77,11 @@ class ControllerTest extends \Test\TestCase {
'session' => ['sezession' => 'kein'],
'method' => 'hi',
],
- $this->getMockBuilder('\OCP\Security\ISecureRandom')
- ->disableOriginalConstructor()
- ->getMock(),
- $this->getMockBuilder(IConfig::class)
- ->disableOriginalConstructor()
- ->getMock()
+ $this->createMock(IRequestId::class),
+ $this->createMock(IConfig::class)
);
- $this->app = $this->getMockBuilder('OC\AppFramework\DependencyInjection\DIContainer')
+ $this->app = $this->getMockBuilder(DIContainer::class)
->setMethods(['getAppName'])
->setConstructorArgs(['test'])
->getMock();