Skip to content

Commit d0b2b7c

Browse files
committed
test: update e2e agent-tool name for the git service
The next-devframe-hub e2e asserted `devframes_plugin_git_status`; git's agent-flagged reads now live on `@devframes/service-git`, so the hub MCP surfaces `devframes_service_git_status`. Also assert the service exposes its agent-flagged status op on the agent surface.
1 parent bdd357b commit d0b2b7c

2 files changed

Lines changed: 16 additions & 2 deletions

File tree

services/git/test/git.test.ts

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -181,4 +181,17 @@ describe('@devframes/service-git', () => {
181181
)
182182
expect(status.isRepo).toBe(true)
183183
})
184+
185+
it('exposes agent-flagged read ops on the agent surface', async () => {
186+
const repo = createTempRepo()
187+
cleanups.push(repo.cleanup)
188+
const ctx = await createHostContext({ cwd: repo.dir, mode: 'dev', host: nullHost(repo.dir) })
189+
void ctx.services.install(createGitService())
190+
await ctx.services.ready()
191+
192+
// Auto-discovered from the RPC `agent` field — the hub's MCP surfaces this
193+
// as `devframes_service_git_status` (the e2e asserts that name).
194+
const tool = ctx.agent.getTool('devframes:service:git:status')
195+
expect(tool?.title).toBe('Git status')
196+
})
184197
})

tests/e2e/next-devframe-hub-dev.spec.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,11 +39,12 @@ test.describe('devframe connect (next-devframe-hub)', () => {
3939
expect(hub.mcp.url).toMatch(/^http:\/\/(?:localhost|127\.0\.0\.1):9878\/__devframes\/__mcp$/)
4040

4141
// The hub's agent surface flows through: the agent-flagged hub command,
42-
// the built-in devframe_state_read, and the git plugin's agent-flagged reads.
42+
// the built-in devframe_state_read, and the git service's agent-flagged
43+
// reads (the git plugin now exposes git through `@devframes/service-git`).
4344
const toolNames = hub.mcp.tools.map((t: any) => t.name)
4445
expect(toolNames).toContain('example_next-devframe-hub_ping')
4546
expect(toolNames).toContain('devframe_state_read')
46-
expect(toolNames).toContain('devframes_plugin_git_status')
47+
expect(toolNames).toContain('devframes_service_git_status')
4748

4849
// Call the agent-flagged hub command through the connector.
4950
const ping = parseToolText(await client.callTool({

0 commit comments

Comments
 (0)