fix(adapters): wrap redacted MCP output in CallToolResult #452
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Integration Tests | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| workflow_dispatch: | |
| inputs: | |
| agent_url: | |
| description: 'AxonFlow Agent URL (defaults to staging)' | |
| required: false | |
| default: 'https://staging-eu.getaxonflow.com' | |
| permissions: | |
| contents: read | |
| env: | |
| DO_NOT_TRACK: '1' | |
| # Note: github.event.inputs only available on workflow_dispatch, defaults used otherwise | |
| AXONFLOW_AGENT_URL: ${{ github.event.inputs.agent_url || 'https://staging-eu.getaxonflow.com' }} | |
| AXONFLOW_CLIENT_ID: ${{ secrets.AXONFLOW_CLIENT_ID || 'demo-client' }} | |
| AXONFLOW_CLIENT_SECRET: ${{ secrets.AXONFLOW_CLIENT_SECRET || 'demo-secret' }} | |
| jobs: | |
| contract-tests: | |
| name: Contract Tests | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.11' | |
| - name: Install dependencies | |
| run: pip install -e ".[dev]" | |
| - name: Run contract tests | |
| run: pytest tests/test_contract.py -v --no-cov | |
| integration-tests: | |
| name: Integration Tests | |
| runs-on: ubuntu-latest | |
| # Only run on main branch or manual dispatch with secrets configured | |
| if: github.event_name == 'workflow_dispatch' || (github.ref == 'refs/heads/main' && github.event_name == 'push') | |
| needs: contract-tests | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.11' | |
| - name: Install dependencies | |
| run: pip install -e ".[dev,all]" | |
| - name: Run integration tests | |
| env: | |
| RUN_INTEGRATION_TESTS: '1' | |
| AXONFLOW_LICENSE_KEY: ${{ secrets.AXONFLOW_LICENSE_KEY }} | |
| run: pytest tests/test_integration.py -v --no-cov | |
| continue-on-error: true # Don't fail build if staging is down | |
| demo-scripts: | |
| name: Demo Scripts Validation | |
| runs-on: ubuntu-latest | |
| needs: contract-tests | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.11' | |
| - name: Install dependencies | |
| run: pip install -e ".[dev,all]" | |
| - name: Validate quickstart.py syntax | |
| run: python -m py_compile examples/quickstart.py | |
| - name: Validate gateway_mode.py syntax | |
| run: python -m py_compile examples/gateway_mode.py | |
| - name: Validate openai_integration.py syntax | |
| run: python -m py_compile examples/openai_integration.py | |
| - name: Run quickstart (dry-run mode) | |
| run: | | |
| python -c " | |
| import asyncio | |
| from examples.quickstart import main | |
| # Verify module imports correctly | |
| print('quickstart.py imports successfully') | |
| " | |
| - name: Run gateway_mode (dry-run mode) | |
| run: | | |
| python -c " | |
| import asyncio | |
| from examples.gateway_mode import main, blocked_example | |
| # Verify module imports correctly | |
| print('gateway_mode.py imports successfully') | |
| " | |
| community-stack-tests: | |
| name: Community Stack E2E | |
| runs-on: ubuntu-latest | |
| if: github.event_name == 'workflow_dispatch' | |
| needs: [contract-tests, demo-scripts] | |
| services: | |
| agent: | |
| image: ghcr.io/getaxonflow/axonflow-agent:latest | |
| ports: | |
| - 8080:8080 | |
| env: | |
| AXONFLOW_MODE: community | |
| AXONFLOW_DEBUG: 'true' | |
| options: >- | |
| --health-cmd "wget --spider -q http://localhost:8080/health || exit 1" | |
| --health-interval 10s | |
| --health-timeout 5s | |
| --health-retries 5 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.11' | |
| - name: Install dependencies | |
| run: pip install -e ".[dev,all]" | |
| - name: Wait for agent to be ready | |
| run: | | |
| for i in {1..30}; do | |
| if curl -s http://localhost:8080/health | grep -q healthy; then | |
| echo "Agent is ready!" | |
| exit 0 | |
| fi | |
| echo "Waiting for agent... ($i/30)" | |
| sleep 2 | |
| done | |
| echo "Agent failed to start" | |
| exit 1 | |
| - name: Run SDK against community stack | |
| env: | |
| AXONFLOW_AGENT_URL: 'http://localhost:8080' | |
| AXONFLOW_CLIENT_ID: 'test-client' | |
| AXONFLOW_CLIENT_SECRET: 'test-secret' | |
| RUN_INTEGRATION_TESTS: '1' | |
| run: | | |
| # Run integration tests against local community stack | |
| pytest tests/test_integration.py -v --no-cov | |
| - name: Run demo scripts against community stack | |
| env: | |
| AXONFLOW_AGENT_URL: 'http://localhost:8080' | |
| AXONFLOW_CLIENT_ID: 'test-client' | |
| AXONFLOW_CLIENT_SECRET: 'test-secret' | |
| run: | | |
| # Run quickstart demo | |
| python examples/quickstart.py || echo "Quickstart completed (may fail without LLM)" |