History improvement add alert only 11 incidents stored (#640) #365
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 Cypress Tests | |
on: | |
push: | |
branches: | |
- master | |
- dev | |
- dev2 | |
jobs: | |
chrome: | |
runs-on: ubuntu-latest | |
name: E2E on Chrome | |
steps: | |
- name: Checkout 🔖 | |
uses: actions/[email protected] | |
- name: Setup Node.js 🔨 | |
uses: actions/[email protected] | |
with: | |
node-version: 20 | |
- name: Set Test Domain Environment Variable | |
run: | | |
if [ "${{ github.ref_name }}" == "master" ]; then | |
echo "TEST_DOMAIN=ssl-secure-srv.org" >> $GITHUB_ENV | |
elif [ "${{ github.ref_name }}" == "dev" ]; then | |
echo "TEST_DOMAIN=honeypdfs.com" >> $GITHUB_ENV | |
elif [ "${{ github.ref_name }}" == "dev2" ]; then | |
echo "TEST_DOMAIN=syruppdfs.com" >> $GITHUB_ENV | |
else | |
echo "No matching branch for domain testing. Exiting." && exit 1 | |
fi | |
- name: Debug Test Domain | |
run: echo "TEST_DOMAIN=${{ env.TEST_DOMAIN }}" | |
- name: Execute Cypress Tests 🌡️ | |
uses: cypress-io/[email protected] | |
with: | |
working-directory: ./cypress-tests | |
command: npx cypress run --headless --browser chrome --env TEST_DOMAIN=${{ env.TEST_DOMAIN }} | |
- name: Upload screenshots of tests failed 📷 | |
uses: actions/[email protected] | |
if: failure() | |
with: | |
name: cypress-screenshots | |
path: cypress-tests/cypress/screenshots |