Skip to content

fix(tests): skip integration tests when credentials are missing#62

Open
quanticsoul4772 wants to merge 1 commit intomainfrom
fix/skip-integration-tests-without-creds
Open

fix(tests): skip integration tests when credentials are missing#62
quanticsoul4772 wants to merge 1 commit intomainfrom
fix/skip-integration-tests-without-creds

Conversation

@quanticsoul4772
Copy link
Copy Markdown
Owner

Problem

The `Test (1.24.x)` CI job has been failing since at least 2026-03-02 on every Dependabot PR. Root cause: `checkRequiredEnv()` and `checkNeo4jConnectivity()` call `t.Fatal()` when `VOYAGE_API_KEY`, `ANTHROPIC_API_KEY`, or Neo4j env vars are not set.

Fix

Changed `t.Fatal`/`t.Fatalf` → `t.Skip`/`t.Skipf` in both helpers. When credentials are absent tests report SKIP instead of FAIL — unblocking CI for PRs that don't carry secrets. Behaviour is identical when credentials are present.

Affected tests (all now skip cleanly without creds)

TestMCPClientStartStop, TestMCPClientThinkTool, TestMCPExecutorE2E, TestMCPVsDirectPerformance, TestMCPExecutorServerCrash, TestMCPExecutorConnectionReuse, TestMCPConcurrentCalls, TestMCPProtocolMismatch, TestMCPExecutorTimeout, TestMCPExecutorInvalidResponse

Test plan

  • No other `t.Fatal` on missing env vars found in `benchmarks/`
  • Behaviour unchanged when credentials are present

🤖 Generated with Claude Code

checkRequiredEnv() and checkNeo4jConnectivity() called t.Fatal() when
VOYAGE_API_KEY, ANTHROPIC_API_KEY, or Neo4j env vars were absent. This
caused all benchmark integration tests to FAIL in CI environments that
don't have those secrets configured, even though the logic under test
requires no live services.

Change t.Fatal/t.Fatalf → t.Skip/t.Skipf throughout both helpers so
that the test run reports SKIP rather than FAIL when credentials are
unavailable. When the secrets ARE present the tests run exactly as
before.

This unblocks the CI Test job for Dependabot/merge-queue PRs that have
been failing since at least 2026-03-02 due to missing VOYAGE_API_KEY.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@github-actions
Copy link
Copy Markdown
Contributor

Benchmark Results


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant