File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed
packages/internal/src/db/__tests__ Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -54,8 +54,14 @@ const DEFAULT_TEST_DATABASE_URL =
5454 'postgresql://postgres:postgres@127.0.0.1:5432/testdb'
5555const TEST_DATABASE_URL = process . env . DATABASE_URL || DEFAULT_TEST_DATABASE_URL
5656
57- // Skip tests if DATABASE_URL is not configured (e.g., in unit test runs)
58- const SKIP_INTEGRATION_TESTS = ! process . env . DATABASE_URL && ! process . env . RUN_INTEGRATION_TESTS
57+ // Skip tests if:
58+ // 1. Running in GitHub Actions CI (which doesn't have a real Postgres for packages/internal)
59+ // 2. DATABASE_URL is not configured locally and RUN_INTEGRATION_TESTS is not set
60+ // Note: CI injects DATABASE_URL as a secret, but there's no actual database running
61+ // for packages/internal integration tests (only packages/billing has Postgres in CI)
62+ const SKIP_INTEGRATION_TESTS =
63+ process . env . CODEBUFF_GITHUB_ACTIONS === 'true' ||
64+ ( ! process . env . DATABASE_URL && ! process . env . RUN_INTEGRATION_TESTS )
5965
6066// Create test database connection
6167let testClient : ReturnType < typeof postgres > | null = null
You can’t perform that action at this time.
0 commit comments