This directory contains CI/CD workflows for the Pilot Protocol project.
graph TD
A[Push to main/build/**] --> B[Tests Workflow]
B --> C[Unit Tests]
C --> D[Integration Tests]
D --> E[Test Summary]
E -->|Success| F[Publish Python SDK]
E -->|Failure| G[Stop - No Publish]
F --> H{Environment}
H -->|main branch| I[Publish to PyPI]
H -->|build/** branch| J[Publish to TestPyPI]
Triggers: Push to main, build/**, docs/**, PRs to main
Jobs:
-
unit-tests: Runs Go unit tests (
./tests/...)- Generates coverage report
- Uploads coverage artifact
- Timeout: 5 minutes
-
integration-tests: Runs Docker integration tests
- Depends on: unit-tests
- Runs CLI tests (21 tests)
- Runs Python SDK tests (34 tests)
- Timeout: 10 minutes
-
test-summary: Aggregates results
- Depends on: unit-tests, integration-tests
- Fails if any test suite fails
- Displays summary in GitHub UI
Total Tests: 55+ (Go unit tests + 21 CLI + 34 SDK integration tests)
Triggers:
- Manual workflow dispatch
- Automatic after "Tests" workflow completes (on
mainorbuild/**)
Dependencies:
⚠️ Requires "Tests" workflow to pass before publishing- Will NOT publish if any tests fail
Jobs:
- check-tests: Validates test workflow passed
- setup: Determines environment (production vs test)
- build-wheels: Builds for Linux and macOS
- publish: Publishes to PyPI or TestPyPI
- test-install: Verifies installation works
Behavior:
mainbranch → Production PyPIbuild/**branches → TestPyPI- Manual dispatch → Choose environment
Triggers: Push to main, PRs, weekly schedule
Purpose: Security scanning using GitHub CodeQL
✅ All workflows use FREE GitHub-hosted runners for public repos:
ubuntu-latest: FREEmacos-latest: FREE
Total Cost: $0/month
# Run all tests
make test
# Run integration tests only
cd tests/integration && make test
# Run unit tests only
go test -v ./tests/...Tests Workflow (tests.yml)
↓
├─ Unit Tests (Go)
├─ Integration Tests (Docker: CLI + SDK)
└─ Test Summary
↓
└─ (on success) triggers →
↓
Publish Python SDK (publish-python-sdk.yml)
↓
├─ Build Wheels
├─ Publish to PyPI/TestPyPI
└─ Verify Installation
- Test-First Publishing: SDK only publishes after ALL tests pass
- Multi-Platform: Builds Linux and macOS wheels
- Coverage Reports: Automatic coverage generation and artifact upload
- Environment Safety: Test environment (TestPyPI) for
build/**branches - Comprehensive Testing: Unit + Integration (CLI + SDK) tests
- Free Runners: Zero cost for public repository
