refactor(result): Adapt tests to new result methods

Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
This commit is contained in:
Carl Schwan 2025-11-19 11:41:49 +01:00
parent 90f4b98424
commit 59e652907b
3 changed files with 4 additions and 5 deletions

View file

@ -422,7 +422,7 @@ EOF;
$stmt->expects($this->once())
->method('fetchAssociative')
->willReturn($return);
->willReturn($return ?? false);
$stmt->expects($this->once())
->method('closeCursor');

View file

@ -58,8 +58,7 @@ class RefreshWebcalJobRegistrarTest extends TestCase {
->willReturn($statement);
$statement->expects($this->exactly(4))
->method('fetch')
->with(\PDO::FETCH_ASSOC)
->method('fetchAssociative')
->willReturnOnConsecutiveCalls(
[
'principaluri' => 'foo1',
@ -73,7 +72,7 @@ class RefreshWebcalJobRegistrarTest extends TestCase {
'principaluri' => 'foo3',
'uri' => 'bar3',
],
null
false,
);
$this->jobList->expects($this->exactly(3))

View file

@ -80,7 +80,7 @@ class RemoveDeletedUsersCalendarSubscriptionsTest extends TestCase {
->willReturn(count($subscriptions));
$result
->method('fetch')
->method('fetchAssociative')
->willReturnOnConsecutiveCalls(...$subscriptions);
$qb->method('delete')