Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,21 @@ jobs:
cp ./packages/web/.env.example ./packages/web/.env
- name: Install dependencies
run: npm ci
- name: Install Playwright browser
run: npm exec --workspace=@eheikes/oscar-web -- playwright install --with-deps chromium
- name: Start API server for web tests
run: |
NODE_ENV=test PORT=3000 CORS_ALLOWED_ORIGIN=https://127.0.0.1:4173 RATE_LIMITING_MAX=100000 \
npm run start --workspace=@eheikes/oscar-api > /tmp/oscar-api.log 2>&1 &
# Any HTTP response (even a 401) means the server is up.
for i in {1..30}; do
if curl -sS -o /dev/null http://localhost:3000/items; then
echo "API is ready"
break
fi
sleep 1
done
curl -sS -o /dev/null http://localhost:3000/items || { cat /tmp/oscar-api.log; exit 1; }
- name: Run linter
run: npm run lint --if-present
- name: Run build
Expand Down
Loading
Loading