Skip to content

ci: test

ci: test #41

Workflow file for this run

name: Build
env:
PACT_BROKER_WEBHOOK_HOST_WHITELIST: localhost
on:
push:
workflow_dispatch:
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '20'
- run: docker compose up -d
- run: npm i
- run: nohup npm run start --prefix broker-webhook > out.log 2>&1 &
- run: npm run create-webhook --prefix broker-webhook
- run: npm test --prefix consumer
- run: |
npm run pact:publish --prefix consumer > publish.out
sleep 15
curl "$(cat publish.out | grep "View logs at" | sed -E 's/.*View logs at \x1b\[35m(.*)\x1b\[0m/\1/')" --user pact_workshop:pact_workshop -H "Accept: */*"
- run: sleep 15
- run: cat out.log