Skip to content

fix(task) #29 #30 #31 #32 #33 SOAP options and headers per call, SoapFault handling, input check; #23 add missing tests - #34

Merged
njoubert-cleverage merged 1 commit into
mainfrom
29
Oct 2, 2026
Merged

njoubert-cleverage merged 1 commit into
mainfrom
29

Conversation

@njoubert-cleverage

Copy link
Copy Markdown
Member

Description

Fixes #23.
Fixes #29.
Fixes #30.
Fixes #31.
Fixes #32.
Fixes #33.

Grouped in one PR because the fixes change the same task, transformer, client, tests, reference pages and the CHANGELOG Latest section.

SOAP options and headers per call (#29, #30)

SOAP faults (#31, #32)

Input (#33): RequestTask throws RequestTask expects an array or empty input, <type> given (TypeError from Client::call()); Client::call() logs the notice before a soapCall<Method>() override.

Tests (#23)

  • FakeSoapClient (test helper): a non-WSDL SoapClient answering prepared responses through __doRequest(), without network access (signature compatible from PHP 8.2 to 8.5).
  • ClientTest, RequestTransformerTest, MissingClientExceptionTest, CleverAgeSoapProcessExtensionTest, CleverAgeSoapProcessBundleTest (new); RequestTaskTest rewritten with a real Client: results (including false), headers / options of the client kept, task ones sent for the call only and restored, faults, exceptions: false, overrides, input, header options.

Coverage: 172/172 lines (32 tests). Without the fix, 10 of the tests fail. The bundle test declares every class it runs (RegisterClientsPass included, unlike the rest bundle where it made main fail).

Documentation: request_task.md, request_transformer.md (new options, failures), client.md (failures, exceptions: false, shared state, override example).

Checked with process-bundle-demo and a SOAP service mocked by WireMock (see the demo PR):

Process Before After
demo.soap.client_headers (header from the client definition) "count" : 0 "count" : 1
demo.soap.headers_leak (task header, then soap_request) "count" : 2 "count" : 1
demo.soap.false_result Soap call 'IsAvailable' on client 'wiremock' failed false
demo.soap.fault_without_exceptions SoapFault object output fails
demo.soap.invalid_input TypeError RequestTask expects an array or empty input, string given
demo.soap, demo.soap.call_failure, demo.soap.call_failure_skip unchanged

Not changed: the Empty resultset for query error message (misleading, but used by the documentation and the cookbook).

Requirements

  • Documentation updates
    • Reference
    • Changelog
  • Unit tests

Breaking changes

🤖 Generated with Claude Code

…Fault thrown, input check; #23 add missing tests

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment