test(domain): withdrawal cancels the workflow via the Beoordelen task's execution (refs #12)

The WithdrawRegistration handler delivers the withdrawal message to the open Beoordelen task's

execution; the Workflow Client PUTs messageEventReceived (RegistratieIngetrokken). BeoordelingTask

now carries its executionId.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-07-16 11:29:56 +02:00
parent 435db81bdf
commit 2a6874ef6d
5 changed files with 78 additions and 9 deletions

View File

@@ -47,6 +47,7 @@ internal sealed class FakeUserTaskClient(IReadOnlyList<BeoordelingTask> open) :
{
public (string TaskId, string Behandelaar)? Claimed { get; private set; }
public (string TaskId, BeoordelingsBesluit Besluit)? Completed { get; private set; }
public string? WithdrawnExecutionId { get; private set; }
public Task<IReadOnlyList<BeoordelingTask>> GetOpenBeoordelingenAsync(CancellationToken ct = default)
=> Task.FromResult(open);
@@ -62,6 +63,12 @@ internal sealed class FakeUserTaskClient(IReadOnlyList<BeoordelingTask> open) :
Completed = (taskId, besluit);
return Task.CompletedTask;
}
public Task WithdrawBeoordelingAsync(string executionId, CancellationToken ct = default)
{
WithdrawnExecutionId = executionId;
return Task.CompletedTask;
}
}
/// <summary>A fake ACL client that records the bsn it was asked to open a zaak for and returns a