Add comprehensive subscriber examples with CI verification #446
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: Pull Request | |
| on: | |
| pull_request: | |
| branches: | |
| - main | |
| - alpha | |
| permissions: | |
| contents: read | |
| checks: write | |
| jobs: | |
| pull_request: | |
| uses: makerxstudio/shared-config/.github/workflows/node-ci.yml@main | |
| with: | |
| node-version: 20.x | |
| working-directory: ./ | |
| run-commit-lint: true | |
| run-build: true | |
| pre-test-script: | | |
| pipx install algokit | |
| algokit localnet start | |
| npx --yes wait-on tcp:4001 -t 30000 | |
| audit-script: | | |
| npm run audit | |
| check_docs: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Clone repository | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 1 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20.x | |
| - name: Install root dependencies | |
| run: npm ci | |
| - name: Install docs dependencies | |
| run: npm ci --prefix docs | |
| - name: Verify documentation builds | |
| run: npm run docs:build | |
| verify_examples: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout source code | |
| uses: actions/checkout@v4 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20.x | |
| cache: 'npm' | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Build | |
| run: npm run build | |
| - name: Start LocalNet | |
| run: | | |
| pipx install algokit | |
| algokit localnet start | |
| npx --yes wait-on tcp:4001 -t 30000 | |
| - name: Install examples dependencies | |
| working-directory: examples/subscriber | |
| run: npm ci | |
| - name: Verify all examples | |
| working-directory: examples/subscriber | |
| run: ./verify-all.sh |