Skip to content

Added beta version #594

Added beta version

Added beta version #594

Workflow file for this run

name: Test Mobstac Awesome QR
on: [push]
jobs:
test:
name: Testing QR Library
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2-beta
with:
node-version: '14'
- name: Install dependencies
run: npm install
- name: Run unit tests
run: |
cp -r ./src/tests/qrTests/. ./src/tests/qrTestsOld
npm run test
- name: Compare files
run: |
chmod +x ./.github/workflows/compare_files.sh
exec ./.github/workflows/compare_files.sh
- name: Test Failure
if: ${{ failure() }}
shell: bash
env:
CHANNEL: 'github-notifications'
TITLE: 'workflow-failed'
REPOSITORY_NAME: 'mobstac-awesome-qr'
RUN_ID: ${{ github.run_id }}
ACTOR: ${{ github.actor }}
COLOR: '#FF0000'
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
run: |
curl --request POST \
--url $SLACK_WEBHOOK_URL \
--header 'Content-Type: application/json' \
--header 'cache-control: no-cache' \
--data "{\"channel\":\"${CHANNEL}\", \"attachments\": [ { \"title\":\"${TITLE} [ ${GITHUB_REF##*/} ] : [ ${ACTOR} ]\", \"text\": \"https://github.com/mobstac/${REPOSITORY_NAME}/actions/runs/${RUN_ID}\", \"color\": \"${COLOR}\" } ]}"