Skip to content

CLI-822: Add --task-wait option to API commands #2578

CLI-822: Add --task-wait option to API commands

CLI-822: Add --task-wait option to API commands #2578

Triggered via pull request November 18, 2024 22:26
Status Failure
Total duration 53s
Artifacts

mutation.yml

on: pull_request
Mutation Testing
43s
Mutation Testing
Fit to window
Zoom out
Zoom in

Annotations

1 error and 2 warnings
Mutation Testing
Process completed with exit code 1.
Mutation Testing: src/Command/Api/ApiBaseCommand.php#L138
Escaped Mutant for Mutator "Ternary": --- Original +++ New @@ @@ } $notificationUuid = CommandBase::getNotificationUuidFromResponse($response); $success = $this->waitForNotificationToComplete($this->cloudApiClientService->getClient(), $notificationUuid, "Waiting for task {$notificationUuid} to complete"); - return $success ? Command::SUCCESS : Command::FAILURE; + return $success ? Command::FAILURE : Command::SUCCESS; } public function setMethod(string $method) : void {
Mutation Testing: src/Command/Api/ApiCommandHelper.php#L104
Escaped Mutant for Mutator "LogicalAnd": --- Original +++ New @@ @@ $inputDefinition = array_merge($inputDefinition, $bodyInputDefinition); } // Add --task-wait parameter for responses with notifications. - if (array_key_exists('responses', $schema) && array_key_exists(202, $schema['responses'])) { + if (array_key_exists('responses', $schema) || array_key_exists(202, $schema['responses'])) { $inputDefinition[] = new InputOption('task-wait', null, InputOption::VALUE_NONE, 'Wait for this task to complete'); } $command->setDefinition(new InputDefinition($inputDefinition));