Skip to content

WooCommerce Error Icon Display Inconsistency in Product Description with neve Theme #5942

WooCommerce Error Icon Display Inconsistency in Product Description with neve Theme

WooCommerce Error Icon Display Inconsistency in Product Description with neve Theme #5942

name: Trigger visual on PR comment
on:
issue_comment:
types: [created]
jobs:
trigger_visual:
runs-on: ubuntu-latest
outputs:
triggered: ${{ steps.check.outputs.triggered }}
pr_number: ${{ steps.find-pull-request.outputs.number }}
commit_sha: ${{ steps.find-pull-request.outputs.head-sha }}
steps:
- uses: khan/pull-request-comment-trigger@master
id: check
with:
trigger: "@pirate-bot test:visual"
reaction: eyes
env:
GITHUB_TOKEN: "${{ secrets.BOT_TOKEN }}"
- name: Find Pull Request
uses: juliangruber/find-pull-request-action@v1
id: find-pull-request
with:
github-token: ${{ secrets.BOT_TOKEN }}
branch: development
debug:
needs: trigger_visual
runs-on: ubuntu-latest
steps:
- name: Dump GitHub context
env:
GITHUB_CONTEXT: ${{ toJson(github) }}
run: echo "$GITHUB_CONTEXT"
- name: Dump Output
env:
GITHUB_OUTPUT_STEP: ${{ toJson(needs.trigger_visual.outputs) }}
run: echo "$GITHUB_OUTPUT_STEP"
run-visual:
needs: trigger_visual
# Check if :
# * the author of the comment is part of Org
# * the comment should trigger the action
# * the comment is on the right pr
#
if: "contains('COLLABORATOR,CONTRIBUTOR,MEMBER,OWNER', github.event.comment.author_association) && needs.trigger_visual.outputs.triggered == 'true' && contains(github.event.comment.html_url,join(needs.trigger_visual.outputs.pr_number,'#'))"
env:
CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }}
PERCY_TOKEN: ${{ secrets.PERCY_TOKEN }}
strategy:
matrix:
machines: [1, 2, 3, 4]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
ref: ${{ needs.trigger_visual.outputs.commit_sha }}
- name: Setup node 14
uses: actions/setup-node@v1
with:
node-version: 14.x
- uses: actions/cache@v1
with:
path: ~/.cache/Cypress
key: cypress-cache-v2-${{ runner.os }}-${{ hashFiles('**/package.json') }}
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn cache dir)"
- uses: actions/cache@v2
id: yarn-cache
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: Install deps
run: |
yarn install --frozen-lockfile
yarn run build
- name: Run Visual Diff
env:
PERCY_PARALLEL_TOTAL: 4
PERCY_BRANCH: development
PERCY_COMMIT: ${{ needs.trigger_visual.outputs.commit_sha }}
PERCY_PULL_REQUEST: ${{ needs.trigger_visual.outputs.pr_number }}
PERCY_PARALLEL_NONCE: "${{ github.run_id }}-${{ needs.trigger_visual.outputs.commit_sha }}"
run: |
cd e2e-tests && yarn run visual:test -- --browser chrome --record --parallel --group visual-diff