From 44e76d688f33d3bb81e3d3727941c5e50a4105d4 Mon Sep 17 00:00:00 2001 From: Peter Hirn Date: Tue, 1 Oct 2024 11:19:20 +0200 Subject: [PATCH] chore: testing playwright action --- .github/actions/playwright/action.yml | 34 +++++++++++++++++++++++++++ .github/workflows/check.yml | 11 +++++++-- release-please-config.json | 1 - 3 files changed, 43 insertions(+), 3 deletions(-) create mode 100644 .github/actions/playwright/action.yml diff --git a/.github/actions/playwright/action.yml b/.github/actions/playwright/action.yml new file mode 100644 index 0000000..c53d6e9 --- /dev/null +++ b/.github/actions/playwright/action.yml @@ -0,0 +1,34 @@ +name: playwright + +inputs: + version: + description: Playwright version + required: false + run: + description: Script to execute + required: true + type: string + +runs: + using: composite + steps: + - name: Setup playwright + id: setup + shell: bash + env: + PLAYWRIGHT_VERSION: v1.47.2-noble@sha256:f640d04686ef8fcca228955dc73f36b86ccd2228eda488fb2b32f3f037639f09 + run: | + TMP_DIR="$(mktemp -d)" + SCRIPT_PATH="${TMP_DIR}/run.sh" + echo "${{ inputs.run }}" > "${SCRIPT_PATH}" + chmod +x "${SCRIPT_PATH}" + echo "script=${SCRIPT_PATH}" >> ${GITHUB_OUTPUT} + + CONTAINER="docker://mcr.microsoft.com/playwright:${{ inputs.version || PLAYWRIGHT_VERSION }}" + echo ${CONTAINER} + echo "container=${CONTAINER}" >> ${GITHUB_OUTPUT} + + - name: Run playwright + uses: ${{ steps.setup.outputs.container }} + with: + args: ${{ steps.setup.outputs.script }} diff --git a/.github/workflows/check.yml b/.github/workflows/check.yml index 5ba509f..0d2b660 100644 --- a/.github/workflows/check.yml +++ b/.github/workflows/check.yml @@ -8,8 +8,15 @@ jobs: if: ${{ !startsWith(github.event.head_commit.message, 'release:') }} runs-on: ubuntu-24.04 steps: - - name: Check - run: echo check + - name: Checkout + uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4 + + - name: Playwright + uses: ./.github/actions/playwright + with: + run: | + echo hello + echo more lines - name: Alpine id: alpine diff --git a/release-please-config.json b/release-please-config.json index a8912ff..0acd909 100644 --- a/release-please-config.json +++ b/release-please-config.json @@ -13,7 +13,6 @@ { "type": "test", "section": "Tests" }, { "type": "build", "section": "Build System" }, { "type": "ci", "section": "Continuous Integration" }, - { "type": "infra", "section": "Infrastructure" }, { "type": "release", "section": "Releases", "hidden": true } ], "pull-request-title-pattern": "release: ${version}",