Skip to content

Commit

Permalink
Merge pull request #121 from ZeitOnline/ZO-4407
Browse files Browse the repository at this point in the history
ZO-4407: Run tests via GHA
  • Loading branch information
wosc authored Jan 10, 2024
2 parents 800113f + ef2ad78 commit a97f9ab
Showing 1 changed file with 42 additions and 0 deletions.
42 changes: 42 additions & 0 deletions .github/workflows/testrunner.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: Testrunner

on:
push:
branches:
- "main"
pull_request:

env:
PROJECT: zappi-spec
BUILD_URL: "${{github.server_url}}/${{github.repository}}/actions/runs/${{github.run_id}}"

jobs:
test:
runs-on: zon-ubuntu-general-dind
permissions:
contents: "read"

steps:
- uses: actions/checkout@v4.1.1

- uses: actions/setup-python@v5.0.0
with:
python-version: "3.12"
cache: "pipenv"
- run: pip install pipenv

- uses: actions/setup-node@v4.0.0
with:
node-version: "20"
cache: "npm"
cache-dependency-path: "docs/api/package-lock.json"

- run: bin/test

- uses: slackapi/slack-github-action@v1.24.0
if: failure() && github.ref_name == 'main'
with:
channel-id: "${{secrets.SLACK_TEAM_CONTENT_CHANNEL_ID}}"
slack-message: ":small_red_triangle_down: <${{env.BUILD_URL}}|${{env.PROJECT}}> tests failed"
env:
SLACK_BOT_TOKEN: ${{secrets.SLACK_BOT_TOKEN}}

0 comments on commit a97f9ab

Please sign in to comment.