Repository navigation
Integration (opt-in) #1
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 (opt-in) | |
| on: | |
| workflow_dispatch: | |
| inputs: | |
| reason: | |
| description: 'Motivo do run (vai pro log)' | |
| required: false | |
| default: 'manual' | |
| permissions: | |
| contents: read | |
| concurrency: | |
| group: integration | |
| cancel-in-progress: false | |
| jobs: | |
| integration: | |
| name: Integration suite contra sandbox NFE.io | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 15 | |
| env: | |
| NFE_SDK_E2E: '1' | |
| NFE_SDK_E2E_API_KEY: ${{ secrets.NFE_SDK_E2E_API_KEY }} | |
| NFE_SDK_E2E_DATA_API_KEY: ${{ secrets.NFE_SDK_E2E_DATA_API_KEY }} | |
| NFE_SDK_E2E_COMPANY_ID: ${{ secrets.NFE_SDK_E2E_COMPANY_ID }} | |
| NFE_SDK_E2E_WEBHOOK_SECRET: ${{ secrets.NFE_SDK_E2E_WEBHOOK_SECRET }} | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Setup PHP | |
| uses: shivammathur/setup-php@v2 | |
| with: | |
| php-version: '8.2' | |
| extensions: curl, json, mbstring | |
| coverage: none | |
| tools: composer:v2 | |
| - name: Install dependencies | |
| run: composer install --prefer-dist --no-progress --no-interaction | |
| - name: Verifica que secrets estão presentes | |
| run: | | |
| if [ -z "$NFE_SDK_E2E_API_KEY" ] || [ -z "$NFE_SDK_E2E_COMPANY_ID" ]; then | |
| echo "::error::Secrets NFE_SDK_E2E_API_KEY e NFE_SDK_E2E_COMPANY_ID precisam estar configurados no repo (Settings → Secrets)." | |
| exit 1 | |
| fi | |
| - name: Run integration tests | |
| run: vendor/bin/pest tests/Integration --colors=never |