Run QIT #16
This file contains 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: Run QIT | |
# **What it does**: Runs a suite of QIT tests for the extension. | |
# **Why we have it**: To be able to check QIT compatibility at once. For example, to test a specific branch, or upcoming release. | |
on: | |
workflow_dispatch: | |
inputs: | |
wait: | |
description: 'Should wait for results' | |
default: false | |
type: boolean | |
# Configure which tests to run. | |
test-activation: | |
description: 'Should activation be tested?' | |
required: true | |
default: true | |
type: boolean | |
test-security: | |
description: 'Should security be tested?' | |
required: true | |
default: true | |
type: boolean | |
test-phpstan: | |
description: 'Should phpstan be tested?' | |
required: true | |
default: true | |
type: boolean | |
test-api: | |
description: 'Should API be tested?' | |
required: true | |
default: true | |
type: boolean | |
test-e2e: | |
description: 'Should E2E be tested? (takes a lot of time)' | |
required: true | |
default: false | |
type: boolean | |
# Advanced customization. | |
ignore-fail: | |
description: Should pass even if any awaited test fails. | |
required: false | |
default: false | |
type: boolean | |
options: | |
description: 'Additional options for `qit` command, like `--optional_features=hpos`.' | |
required: false | |
jobs: | |
build: | |
name: Build extension | |
uses: ./.github/workflows/build.yml | |
secrets: inherit | |
qit-tests: | |
name: Run QIT Tests | |
runs-on: ubuntu-20.04 | |
needs: build | |
steps: | |
- name: Download artifact | |
uses: actions/download-artifact@v4 | |
with: | |
name: woocommerce-google-analytics-integration.zip | |
- name: Run QIT Tests | |
# Update it with more stable path once merged. | |
uses: woocommerce/grow/run-qit-extension@actions-v2 | |
with: | |
qit-partner-user: ${{ secrets.QIT_PARTNER_USER }} | |
qit-partner-secret: ${{ secrets.QIT_PARTNER_SECRET }} | |
version: local | |
wait: ${{ inputs.wait }} | |
extension: 'woocommerce-google-analytics-integration' | |
test-activation: ${{ inputs.test-activation }} | |
test-security: ${{ inputs.test-security }} | |
test-phpstan: ${{ inputs.test-phpstan }} | |
test-api: ${{ inputs.test-api }} | |
test-e2e: ${{ inputs.test-e2e }} | |
ignore-fail: ${{ inputs.ignore-fail }} | |
options: ${{ inputs.options }} |