volcano-sh / volcano-sh/agentcube
Umbrella issues for E2E
@MahaoAlex is already working on this.
Since Dec 31, 2025.
- Dominant language
- Go
- Stars
- 167
- Forks
- 88
- Avg merge
- 44m
- Merged PRs (30d)
- 1
Description
Background
We already have e2e_test.go covering previous ssh-based codeinterpreter:
Now have redesigned AgentCube, bring two scenarios:
- AgentRuntime and CodeInterpreter invocation via Agentcube Router
- Session creation and reuse via x-agentcube-session-id
- Session lifecycle and TTL semantics (at least smoke coverage)
This issue tracks adding a first-stage, minimal but concrete e2e suite for both AgentRuntime and CodeInterpreter.
Scope
AgentRuntime e2e
A1. Basic agent invocation: session creation and reuse
Precondition: AgentRuntime CR (e.g. default/echo-agent) deployed.
POST /v1/namespaces/{ns}/agent-runtimes/{name}/invocations/echo without x-agentcube-session-id.
Assert:
- HTTP 200.
- Reasonable response body (e.g. echo output).
- Response header x-agentcube-session-id is present.
Repeat call with that session header and a different request body.
Assert:
- Still HTTP 200.
- Behavior consistent with same session (e.g. same session ID; optional state check if agent supports state).
A2. Missing/invalid AgentRuntime
- Call POST on a non-existent {name}.
- Assert:
- HTTP 404 (or the documented error code).
- Clear error payload (e.g. “AgentRuntime not found”).
A3. Idle session / TTL behavior (smoke test)
- Create a session as in A1 and capture SESSION_ID.
- Wait long enough for idle TTL + cleanup.
- Call with the same SESSION_ID.
-Assert:- Either error indicating session not found.
CodeInterpreter e2e
B1. Simple code execution with session auto-creation
Precondition: CodeInterpreter CR (e.g. default/python-interpreter) deployed.
POST /v1/namespaces/{ns}/code-interpreters/{name}/invocations/run without x-agentcube-session-id.
Body: simple code snippet (e.g. print(1+1)).
- Assert:
- HTTP 200.
- Output (e.g. "stdout":"2\n").
- Response header x-agentcube-session-id is present.
B2. Stateful interpreter session (multi-step)
- Reuse the SESSION_ID from B1.
- Second call: code = "x = 10".
- Third call: code = "print(x)".
- Assert:
- Third response prints 10 (or explicitly assert stateless behavior if we decide CodeInterpreter is stateless initially).
B3. File-based workflow via CodeInterpreter (Fibonacci JSON)
- Use CodeInterpreter API to:
- Upload a small Python script (fibonacci.py) into /workspace.
- Execute it to generate /workspace/output.json.
- Retrieve the JSON result.
- Assert:
- retrieve the result to check.
Corner cases:
- longer delay task execution
- warmer pool/non warmpool
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.