The GitHub Actions job "Required Checks" on 
texera.git/gh-readonly-queue/main/pr-6139-233c4deb2bd646a5e52eea042384caa28400dbf6
 has succeeded.
Run started by GitHub user aglinxinyuan (triggered by aglinxinyuan).

Head commit for run:
48d9e358b4a3d86b0eb8c33ae766742dcefdd44f / Xinyuan Lin <[email protected]>
test(amber): add AsyncRPCClient unit tests for createInvocation and 
logControlReply (#6139)

### What changes were proposed in this PR?

Adds a unit test for `AsyncRPCClient` (`amber` engine RPC), which had no
dedicated spec. The test drives the client with directly-constructed
collaborators (a real `NetworkInputGateway` and a `NetworkOutputGateway`
whose handler captures messages) — no actor system, DB, or network — and
covers the currently-uncovered paths:

- `createInvocation` — carries method name/context, hands back an
unfulfilled future, assigns monotonic command IDs, and `fulfillPromise`
completes the future with the return value (and fails it on a
`ControlError`);
- `logControlReply` — all four branches: the `IgnoreReplyAndDoNotLog`
early-return, the metrics early-return, the `ControlError` error path,
and the null-`returnValue` info path;
- `sendToClient` — forwards exactly one message to the client channel.

No production code is changed; this is test-only.

### Any related issues, documentation, discussions?

Coverage gaps identified from the Codecov report for `apache/texera`.

### How was this PR tested?

New ScalaTest spec, run locally:

```
sbt "WorkflowExecutionService/testOnly *AsyncRPCClientSpec"
```

All 11 pass. `scalafmt` and `scalafixAll --check` are clean.

### Was this PR authored or co-authored using generative AI tooling?

Generated-by: Claude Code (Opus 4.8 [1M context])

Report URL: https://github.com/apache/texera/actions/runs/28817458719

With regards,
GitHub Actions via GitBox

Reply via email to