Repository navigation
test(coding-agent): consolidate session integration coverage - #499
Merged
Merged
Conversation
kevinjosethomas
approved these changes
Jul 22, 2026
zhengr
pushed a commit
to zhengr/prime-agent
that referenced
this pull request
Aug 8, 2026
…tellect-ai#499) * test(coding-agent): consolidate session integration coverage * test(coding-agent): preserve consolidated coverage fixes PrimeIntellect-ai#499 --------- Co-authored-by: Kevin Thomas <kevin.jt2007@gmail.com>
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.
Why
Three older
AgentSessionfiles either rebuilt their own lower-level harness or used credential-gated provider calls that are skipped in required CI. The current deterministic suite harness already covers the broader retry, runtime, and compaction lifecycles.What changes
Coverage and cost
Unique assertions were moved before deletion; existing broader lifecycle tests remain unchanged.
Focused added coverage:
npm run checkThe previous retry file took 38 ms for seven tests. The branching and compaction files were credential-gated and all eight tests were skipped in normal CI. Net reduction: 544 lines.
Note
Low Risk
Test-only refactor with no production code changes; minor risk that a dropped assertion (e.g. persistent content_filter retry cap) is no longer explicitly covered if not duplicated elsewhere.
Overview
Consolidates
AgentSessionintegration coverage into the existingtest/suiteharness so CI no longer depends on API-key-gated real LLM runs or one-off runtime setup.Deletes standalone
agent-session-branching,agent-session-compaction, andagent-session-retrytest files (~645 lines) and adds targeted cases toagent-session-retry-events,agent-session-compaction, andagent-session-runtime: a parameterized table of six transient provider error strings that should auto-retry; a full manual compaction path through the model summarizer (persisted compaction entry,compaction_start/compaction_end, post-compaction prompt); and fork scenarios for middle-of-thread history plus in-memory first-prompt forks withselectedTextmetadata.Refactors runtime suite setup with an
inMemoryoption oncreateRuntimeForTest, reusing it for the in-memory fork-at-position test instead of duplicating faux/runtime boilerplate.Reviewed by Cursor Bugbot for commit 84b6a6c. Bugbot is set up for automated code reviews on this repo. Configure here.
Note
Consolidate AgentSession integration tests into suite directory
test/suite/createRuntimeForTesthelperMacroscope summarized 84b6a6c.