From 6e940f070317563db7126ebcf230aad84191c639 Mon Sep 17 00:00:00 2001 From: Jana Peper Date: Wed, 11 Dec 2024 11:43:20 +0100 Subject: [PATCH] test: add disabled task type unit test Signed-off-by: Jana Peper --- tests/lib/TaskProcessing/TaskProcessingTest.php | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/tests/lib/TaskProcessing/TaskProcessingTest.php b/tests/lib/TaskProcessing/TaskProcessingTest.php index 74504a026fc62..57d34b743f70f 100644 --- a/tests/lib/TaskProcessing/TaskProcessingTest.php +++ b/tests/lib/TaskProcessing/TaskProcessingTest.php @@ -477,7 +477,8 @@ protected function setUp(): void { $taskProcessingTypeSettings = []; $taskProcessingTypeSettings[TextToText::ID] = false; - fwrite(STDERR, print_r($taskProcessingTypeSettings, TRUE)); + fwrite(STDERR, print_r('1', true)); + fwrite(STDERR, print_r($taskProcessingTypeSettings, true)); $disabledConfig = $this->createMock(IConfig::class); $disabledConfig @@ -527,7 +528,8 @@ public function testProviderShouldBeRegisteredAndTaskTypeDisabled(): void { new ServiceRegistration('test', SuccessfulSyncProvider::class) ]); $output = $this->disabledTypeManager->getAvailableTaskTypes(true); - fwrite(STDERR, print_r($output, TRUE)); + fwrite(STDERR, print_r('2', true)); + fwrite(STDERR, print_r($output, true)); self::assertCount(0, $this->disabledTypeManager->getAvailableTaskTypes()); self::assertCount(1, $this->disabledTypeManager->getAvailableTaskTypes(true)); // self::assertFalse($this->disabledTypeManager->hasProviders()); @@ -541,7 +543,8 @@ public function testProviderShouldBeRegisteredAndTaskTypeDisabled2(): void { new ServiceRegistration('test', SuccessfulSyncProvider::class) ]); $output = $this->disabledTypeManager->getAvailableTaskTypes(true); - fwrite(STDERR, print_r($output, TRUE)); + fwrite(STDERR, print_r('3', true)); + fwrite(STDERR, print_r($output, true)); self::assertCount(0, $this->manager->getAvailableTaskTypes()); self::assertCount(1, $this->manager->getAvailableTaskTypes(true)); self::assertFalse($this->manager->hasProviders());