Skip to content

Commit 1819a4f

Browse files
add note about ci
1 parent 5744201 commit 1819a4f

File tree

1 file changed

+33
-0
lines changed

1 file changed

+33
-0
lines changed

CONTRIBUTING.md

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -172,6 +172,39 @@ uv run nox --session test -- --integration
172172

173173
See [`.env.example`](.env.example) for all required variables and their descriptions.
174174

175+
#### Setting up CI Integration Tests
176+
177+
If you want integration tests to run in CI on your fork:
178+
179+
1. Go to your fork's repository settings on GitHub
180+
2. Under "Environments", create a new environment named `integration`
181+
3. Add the following secrets and variables to the environment:
182+
- Secrets
183+
- `TEST_PRIVATE_KEY`
184+
- `TEST_WEBHOOK_SECRET`
185+
- Variables
186+
- `TEST_ACCOUNT_NAME`
187+
- `TEST_ACCOUNT_TYPE`
188+
- `TEST_APP_ID`
189+
- `TEST_CLIENT_ID`
190+
- `TEST_INSTALLATION_ID`
191+
- `TEST_NAME`
192+
193+
> [!NOTE]
194+
> Integration tests in CI will only run with access to these environment secrets. This is a security feature - fork PRs cannot access these secrets unless explicitly granted by repository maintainers.
195+
196+
There is a simple check in the CI workflow that skips the integration test job if `TEST_PRIVATE_KEY` is not configured, preventing unnecessary job runs on unconfigured forks.
197+
198+
#### Security Considerations
199+
200+
The integration test setup is designed to be secure:
201+
202+
- The test GitHub App requires minimal permissions (read-only metadata access)
203+
- It's installed only on your personal account
204+
- Webhooks are disabled to prevent external callbacks
205+
- In CI, tests run in a protected GitHub Environment with restricted secret access
206+
- Fork PRs cannot access integration test secrets (managed automatically by GitHub Actions)
207+
175208
## Linting and Formatting
176209

177210
This project enforces code quality standards using [`pre-commit`](https://github.com/pre-commit/pre-commit).

0 commit comments

Comments
 (0)