Repository navigation
test(evals): Move the conversation integration evals to the agent test fixture - #2018
Merged
Merged
Conversation
…t fixture Move the actions, delivery, lifecycle, and routing integration evals to the agent test fixture. The fixture now mocks image generation at the AI Gateway and Vercel Blob through a local server, and call results include Slack file uploads and the dashboard title. Drop the assistant thread start case, which runs no agent and is covered by assistant-lifecycle-contract.test.ts. Drop the fake active-turn compaction checkpoint; a real compaction case found a loop (#2017). Refs #2001 Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Contributor
|
3 screenshot changes — 3 changed · 0 added · 0 removed Review screenshots in Frameshift
|
dcramer
marked this pull request as ready for review
October 2, 2026 18:34
Agent tests import the fixture as `@junior-evals/fixture/<file>` instead of `../../../src/fixture/<file>`. The test architecture check now accepts only the alias for fixture imports. Refs #2001 Co-Authored-By: Claude Opus 5.5 <[email protected]>
dcramer
added a commit
that referenced
this pull request
Oct 2, 2026
When the turn deadline aborts a running tool call, the turn now always records the attempt as timed out. Before this change, a tool that did not stop on abort could lose the attempt, and the resumed turn could repeat it. In the turn-deadline eval, the agent pushed a release twice. On a turn deadline, the runtime waits 5 seconds for the aborted step to settle, then parks the turn. If a tool call was still running, the parked history ended with a tool call that had no result. `continuableMessages()` trimmed it, so the stored history and the resume history both lost the attempt. The dashboard showed the call as running with no input. Two changes fix this: - **Tool adapter:** after the signal aborts, `createPiAgentTools` waits up to 2 seconds for the tool's own result. Tools that honor the abort, such as sandbox commands, keep their own result and partial output. If the tool does not settle in time, the adapter reports the attempt as preempted through the existing path, which the model sees as `timed_out`. The 2 seconds stay below the agent's 5-second abort settle grace. A tool no longer has to forward the signal for its attempt to be recorded. Work that ignores the signal keeps running in the background, as it did before. - **MCP:** `callMcpTool` now passes the signal to the MCP SDK request, so the request is actually cancelled. Before, it did not, which is how the eval found the bug. The turn-deadline integration eval now checks that the interrupted push is stored with `timed_out: true`. #2018 had removed the old `aborted: true` check because the reporting API had no result for the call. A component test covers a tool that ignores the abort and never settles. Plugin-wrapped MCP calls (`callWrappedTool`) still do not cancel their request, because the plugin API input has no signal. The adapter change still records their attempts. Refs #2001 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Co-authored-by: Claude Opus 5.5 <[email protected]>
dcramer
added a commit
that referenced
this pull request
Oct 6, 2026
#2031) Moves the OAuth integration evals and the Sentry skill evals to the agent test fixture. It adds the last two pieces of the fixture contract in #2001: `completeAuth()` and `insertCredential()`. ```ts const paused = await run(mention("/eval-oauth Connect, then tell me the budget deadline I mentioned."), { history: [threadMessage("Remember: the budget deadline is Friday.")], }); expect(paused.turns.map((turn) => turn.status)).toEqual(["started"]); const resumed = await paused.continue(completeAuth("eval-oauth"), { criteria }); expect(resumed.turns.map((turn) => turn.status)).toEqual(["succeeded"]); ``` - **`completeAuth(provider)`** opens the newest link that Junior sent to the person in private: an ephemeral message, or a normal message when the Conversation is a direct message. A link in a channel message does not count. The mocked provider redirects to the OAuth or MCP OAuth callback route of the app, and the call returns the resumed turn. The `eval-oauth` MSW mock gets an authorize endpoint for this. - **`insertCredential()`** stores an OAuth credential through the user token store. `expired: true` makes its next use refresh it. - Credentials are in Redis, which all tests of a run share. The fixture removes the credentials of a test when the test finishes. - **`auth` suite** (`evals/integration/auth/`): the `eval-auth` and `eval-oauth` plugins are now TypeScript registrations. `global-setup.ts` registers the same ones, because the eval egress process adds credentials to sandbox requests. Their skills load through `SKILL_DIRS`. - **`sentry` suite** (`evals/sentry/`): the Sentry plugin. **Review focus** - The old harness completed the OAuth callback by itself during `run()` and recorded it. Each case now has a paused call and a resumed call, and checks the turn states. The record of the completion is gone: `completeAuth()` fails without a private link to the person. A new case covers a direct message. - The refresh case no longer reads the refresh tokens that the egress process captured. The mock provider accepts only the access token that a refresh returns. - The suites comment on #2001 puts the OAuth evals with the coding suite. They have their own suite, because they need two eval-only plugins and no GitHub or memory plugin. - `fixtures/plugins/eval-operation` is gone. No eval used it after #2018. - The history test "matches the rows of a real Slack turn without a reply" failed in CI on this branch and on others. It asked the model to answer with exactly `[[NO_REPLY]]`. Slack ingress escapes that text, and the model sometimes repeated the escaped text as a reply. The input now asks for no reply and does not name the marker. Eight eval files stay on the old harness: the seven in `evals/agent/` and `evals/github/skills.eval.ts`. Refs #2001 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Co-authored-by: Claude Opus 5.5 <[email protected]>
This branch was successfully deployed
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.
Moves the conversation integration evals (
actions,delivery,lifecycle,routing) to the agent test fixture from #2001. All nine cases now run the real agent through Slack webhooks and read results through the reporting API.Fixture changes
modalities: ["image"]) with a 1x1 PNG. The issue lists image generation as a mocked third-party API. This replaces the old harness'smock_image_generationtool override.sendFilesstores attachments in Vercel Blob, so the fixture now mocks it. The Blob SDK sends uploads and deletes with its ownundicifetch, which MSW cannot see. A local server answers those calls, andVERCEL_BLOB_API_URLpoints the SDK at it. Reads go through MSW. The eval configs set a fakeBLOB_READ_WRITE_TOKEN.files(Slack uploads in the thread) andtitle(the title that the dashboard shows).release-pushmock now ends when the client drops the request. Before this change, it held the call for 45 seconds after a turn deadline.Fixture imports
Agent tests import the fixture through the
@junior-evals/fixture/<file>alias instead of../../../src/fixture/<file>. All existing fixture tests switch over, and the test architecture check accepts only the alias for fixture imports.Case changes
threadStartcase is gone. It runs no agent, andassistant-lifecycle-contract.test.tsalready covers the title and suggested prompts.defineJuniorPluginand setslimits.turnTimeoutMs, instead ofplugin_dirsandturn_timeout_ms. It uses a 15s timeout and names the MCP tools in the prompt, so it fits the 60s call budget. Runs took 36–47s, so the margin is small.aborted: true. The reporting API keeps that call asrunningwith no input or output. The runtime gives the model the aborted result but does not store it in conversation events.active_turn_compactioncheckpoint is gone. A real compaction case, with a smalllimits.contextWindowTokensand large MCP results, found that active-turn compaction can repeat until the turn fails (Active-turn compaction repeats until the turn fails #2017). That case moves to the fix for Active-turn compaction repeats until the turn fails #2017.Refs #2001
🤖 Generated with Claude Code