fix: register the examples/ group in the tsconfig paths map

The @deepseek-ai/dsh-* wildcard maps each package name to its group's
src; the new packages/examples/ group needs its own glob, or the four
moved packages fall back to unbuilt lib/ and vitest cannot resolve them.
Also update the moved specs' plugin export-name assertions (acp-agent ->
acp-demo, stdio-agent -> stdio-demo, agent-core -> agent-spine-demo).
This commit is contained in:
imccyu
2026-07-15 16:05:58 +08:00
parent 2a48b31306
commit e4691a2f79
4 changed files with 7 additions and 6 deletions

View File

@@ -113,7 +113,7 @@ describe('dsh-acp-demo composition', () => {
})
it('exposes its plugin shape', () => {
expect(acpAgent.name).toBe('acp-agent')
expect(acpAgent.name).toBe('acp-demo')
expect(acpAgent.Config).toBeDefined()
})
@@ -147,7 +147,7 @@ describe('dsh-acp-demo composition', () => {
const loader = Object.create(Loader.prototype) as Loader
const unwrapped = loader.unwrapExports(acpAgent) as Record<string, unknown>
expect(unwrapped).toBe(acpAgent)
expect(unwrapped.name).toBe('acp-agent')
expect(unwrapped.name).toBe('acp-demo')
expect(unwrapped.Config).toBeDefined()
expect(typeof unwrapped.apply).toBe('function')
})

View File

@@ -183,7 +183,7 @@ describe('dsh-agent-spine-demo bundle', () => {
it('re-exports the loop config schema as its own', () => {
expect(agentCore.Config).toBeDefined()
expect(agentCore.name).toBe('agent-core')
expect(agentCore.name).toBe('agent-spine-demo')
})
it('has the namespace-plugin export shape (no stray default) so the Loader keeps name/Config/apply', () => {
@@ -195,7 +195,7 @@ describe('dsh-agent-spine-demo bundle', () => {
const loader = Object.create(Loader.prototype) as Loader
const unwrapped = loader.unwrapExports(agentCore) as Record<string, unknown>
expect(unwrapped).toBe(agentCore)
expect(unwrapped.name).toBe('agent-core')
expect(unwrapped.name).toBe('agent-spine-demo')
expect(unwrapped.Config).toBeDefined()
expect(typeof unwrapped.apply).toBe('function')
})

View File

@@ -127,7 +127,7 @@ describe('dsh-stdio-demo app', () => {
})
it('exposes its name and Config schema', () => {
expect(stdioAgent.name).toBe('stdio-agent')
expect(stdioAgent.name).toBe('stdio-demo')
expect(stdioAgent.Config).toBeDefined()
})
@@ -161,7 +161,7 @@ describe('dsh-stdio-demo app', () => {
const loader = Object.create(Loader.prototype) as Loader
const unwrapped = loader.unwrapExports(stdioAgent) as Record<string, unknown>
expect(unwrapped).toBe(stdioAgent)
expect(unwrapped.name).toBe('stdio-agent')
expect(unwrapped.name).toBe('stdio-demo')
expect(unwrapped.Config).toBeDefined()
expect(typeof unwrapped.apply).toBe('function')
})

View File

@@ -60,6 +60,7 @@
"./packages/session-persistence/*/src",
"./packages/session-query/*/src",
"./packages/ui/*/src",
"./packages/examples/*/src",
"./packages/util/*/src",
"./packages/mcp/*/src",
"./packages/support/*/src"