aboutsummaryrefslogtreecommitdiffstats
path: root/tests/lib/TaskProcessing
diff options
context:
space:
mode:
authorMarcel Klehr <mklehr@gmx.net>2024-07-24 15:34:51 +0200
committerJulien Veyssier <julien-nc@posteo.net>2024-07-25 10:10:31 +0200
commit799ee8fd5180e22724d0c188d03ab2a1278b3e1d (patch)
tree982f8af3a39caa75c795cbe36c867b394cc0efd8 /tests/lib/TaskProcessing
parent65941811b326a35bf828879fa0330029d9c75c05 (diff)
downloadnextcloud-server-799ee8fd5180e22724d0c188d03ab2a1278b3e1d.tar.gz
nextcloud-server-799ee8fd5180e22724d0c188d03ab2a1278b3e1d.zip
feat(TaskProcessing): Implement enums and default values
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
Diffstat (limited to 'tests/lib/TaskProcessing')
-rw-r--r--tests/lib/TaskProcessing/TaskProcessingTest.php96
1 files changed, 96 insertions, 0 deletions
diff --git a/tests/lib/TaskProcessing/TaskProcessingTest.php b/tests/lib/TaskProcessing/TaskProcessingTest.php
index c88f73a861c..ac9dec1cd1d 100644
--- a/tests/lib/TaskProcessing/TaskProcessingTest.php
+++ b/tests/lib/TaskProcessing/TaskProcessingTest.php
@@ -104,6 +104,30 @@ class AsyncProvider implements IProvider {
'optionalKey' => new ShapeDescriptor('optional Key', 'AN optional key', EShapeType::Text),
];
}
+
+ public function getInputShapeEnumValues(): array {
+ return [];
+ }
+
+ public function getInputShapeDefaults(): array {
+ return [];
+ }
+
+ public function getOptionalInputShapeEnumValues(): array {
+ return [];
+ }
+
+ public function getOptionalInputShapeDefaults(): array {
+ return [];
+ }
+
+ public function getOutputShapeEnumValues(): array {
+ return [];
+ }
+
+ public function getOptionalOutputShapeEnumValues(): array {
+ return [];
+ }
}
class SuccessfulSyncProvider implements IProvider, ISynchronousProvider {
@@ -138,6 +162,30 @@ class SuccessfulSyncProvider implements IProvider, ISynchronousProvider {
public function process(?string $userId, array $input, callable $reportProgress): array {
return ['output' => $input['input']];
}
+
+ public function getInputShapeEnumValues(): array {
+ return [];
+ }
+
+ public function getInputShapeDefaults(): array {
+ return [];
+ }
+
+ public function getOptionalInputShapeEnumValues(): array {
+ return [];
+ }
+
+ public function getOptionalInputShapeDefaults(): array {
+ return [];
+ }
+
+ public function getOutputShapeEnumValues(): array {
+ return [];
+ }
+
+ public function getOptionalOutputShapeEnumValues(): array {
+ return [];
+ }
}
class FailingSyncProvider implements IProvider, ISynchronousProvider {
@@ -173,6 +221,30 @@ class FailingSyncProvider implements IProvider, ISynchronousProvider {
public function process(?string $userId, array $input, callable $reportProgress): array {
throw new ProcessingException(self::ERROR_MESSAGE);
}
+
+ public function getInputShapeEnumValues(): array {
+ return [];
+ }
+
+ public function getInputShapeDefaults(): array {
+ return [];
+ }
+
+ public function getOptionalInputShapeEnumValues(): array {
+ return [];
+ }
+
+ public function getOptionalInputShapeDefaults(): array {
+ return [];
+ }
+
+ public function getOutputShapeEnumValues(): array {
+ return [];
+ }
+
+ public function getOptionalOutputShapeEnumValues(): array {
+ return [];
+ }
}
class BrokenSyncProvider implements IProvider, ISynchronousProvider {
@@ -207,6 +279,30 @@ class BrokenSyncProvider implements IProvider, ISynchronousProvider {
public function process(?string $userId, array $input, callable $reportProgress): array {
return [];
}
+
+ public function getInputShapeEnumValues(): array {
+ return [];
+ }
+
+ public function getInputShapeDefaults(): array {
+ return [];
+ }
+
+ public function getOptionalInputShapeEnumValues(): array {
+ return [];
+ }
+
+ public function getOptionalInputShapeDefaults(): array {
+ return [];
+ }
+
+ public function getOutputShapeEnumValues(): array {
+ return [];
+ }
+
+ public function getOptionalOutputShapeEnumValues(): array {
+ return [];
+ }
}
class SuccessfulTextProcessingSummaryProvider implements \OCP\TextProcessing\IProvider {