Repository navigation
A scenario that proves the claim (v0.8.0) - #16
Merged
Merged
Conversation
Every other test proves a part. This proves what the README claims: that a team of sessions collaborating through this plugin avoids specific, nameable failures, and that the accounting reports them honestly. A three-session team ships a breaking contract change. Along the way the storyline exercises each failure mode the roadmap targets and pins the exact numbers the report produces — three receiver turns spent, three problems caught: one collision avoided, one false claim refuted before it was acted on, one mutual wait detected. If a change makes collaboration quieter or noisier, those numbers move and this test says so. Nothing is mocked except the two edges the plugin does not own: the agent inbox, since there is no live agent in a unit test, and the session corpus. The stores, sockets, loop control, admission path and metrics are real, writing to a real temporary directory. Two further cases carry the same storyline where a single-process test cannot reach: one across a real Unix socket between hosts, and one pinning the guarantee the whole admission design rests on — that a refuse policy holds whether a message arrives in-process or over a socket, so sharing a process with a receiver is not a way around it. 3 new tests, 308 total. Version 0.8.0.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Every other test proves a part. This proves what the README actually claims: a team of sessions collaborating through this plugin avoids specific, nameable failures — and the accounting reports them honestly.
The storyline
A three-session team ships a breaking contract change, exercising each targeted failure mode in order:
api/api/charges.tsbeneath itThen it pins the exact report:
If a change makes collaboration quieter or noisier, those numbers move and this test says so. That's the point — it's a regression bound on behaviour, not just on code.
What is and isn't mocked
Only the two edges the plugin doesn't own: the agent inbox (no live agent in a unit test) and the session corpus. The stores, sockets, loop control, admission path and metrics are real, writing to a real temp directory.
Two cases a single-process test can't reach
refusepolicy holds whether the message arrives in-process or over a socket. Sharing a process with a receiver is not a way around it.3 new tests, 308 total.