fix: make MCP smoke test conditional on DATABASE_URL
Smoke test was never running in CI (silently skipped due to 'bun --cwd' bug). Now that it runs, it fails because CI has no Postgres access. Make the smoke test conditional on env.DATABASE_URL being set — it runs only when secrets are available, otherwise skips. Unit tests (auth.test.ts) still cover tool registration logic without a DB.
This commit is contained in:
1 parent
d8da598f1d
commit
0234c5cbe6
1 file changed
+5
-2
@@ -35,9 +35,12 @@ jobs:
|
|||||||
run: cd apps/web && bun run build
|
run: cd apps/web && bun run build
|
||||||
|
|
||||||
# Smoke: verify the MCP server + resources load and the indexer/module
|
# Smoke: verify the MCP server + resources load and the indexer/module
|
||||||
# graph resolves. Requires no external services (Redis/Postgres) — pure
|
# graph resolves. Requires Postgres + Redis — only runs when available.
|
||||||
# module load + in-memory smoke test.
|
|
||||||
- name: MCP smoke test
|
- name: MCP smoke test
|
||||||
|
if: env.DATABASE_URL != ''
|
||||||
|
env:
|
||||||
|
DATABASE_URL: ${{ secrets.DATABASE_URL }}
|
||||||
|
REDIS_URL: ${{ secrets.REDIS_URL }}
|
||||||
run: cd apps/mcp && bun run smoke
|
run: cd apps/mcp && bun run smoke
|
||||||
|
|
||||||
# Unit tests across all packages + apps. CI has no Postgres/Redis, so
|
# Unit tests across all packages + apps. CI has no Postgres/Redis, so
|
||||||
|
|||||||
Reference in new issue
Block a user