aboutsummaryrefslogtreecommitdiffstats
path: root/tests/lib/Migration/BackgroundRepairTest.php
diff options
context:
space:
mode:
Diffstat (limited to 'tests/lib/Migration/BackgroundRepairTest.php')
-rw-r--r--tests/lib/Migration/BackgroundRepairTest.php14
1 files changed, 4 insertions, 10 deletions
diff --git a/tests/lib/Migration/BackgroundRepairTest.php b/tests/lib/Migration/BackgroundRepairTest.php
index 25ea6088072..5bc085eb7ec 100644
--- a/tests/lib/Migration/BackgroundRepairTest.php
+++ b/tests/lib/Migration/BackgroundRepairTest.php
@@ -1,4 +1,5 @@
<?php
+
/**
* SPDX-FileCopyrightText: 2016-2024 Nextcloud GmbH and Nextcloud contributors
* SPDX-FileCopyrightText: 2016 ownCloud, Inc.
@@ -54,22 +55,15 @@ class BackgroundRepairTest extends TestCase {
protected function setUp(): void {
parent::setUp();
- $this->jobList = $this->getMockBuilder(JobList::class)
- ->disableOriginalConstructor()
- ->getMock();
- $this->logger = $this->getMockBuilder(LoggerInterface::class)
- ->disableOriginalConstructor()
- ->getMock();
+ $this->jobList = $this->createMock(JobList::class);
+ $this->logger = $this->createMock(LoggerInterface::class);
$this->dispatcher = $this->createMock(IEventDispatcher::class);
$this->time = $this->createMock(ITimeFactory::class);
$this->time->method('getTime')
->willReturn(999999);
$this->appManager = $this->createMock(IAppManager::class);
$this->repair = new Repair($this->dispatcher, $this->logger);
- $this->job = $this->getMockBuilder(BackgroundRepair::class)
- ->setConstructorArgs([$this->repair, $this->time, $this->logger, $this->jobList, $this->appManager])
- ->setMethods(['loadApp'])
- ->getMock();
+ $this->job = new BackgroundRepair($this->repair, $this->time, $this->logger, $this->jobList, $this->appManager);
}
public function testNoArguments(): void {