Skip to content

update to latest test utils #396

update to latest test utils

update to latest test utils #396

Workflow file for this run

# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs
name: Build and Test CI
on:
workflow_dispatch:
push:
branches: ["main"]
pull_request:
permissions:
checks: write
pull-requests: write
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Use Node.js 18
uses: actions/setup-node@v3
with:
node-version: 18.18.2
cache: "npm"
- run: npx yarn install --frozen-lockfile
- name: Build Angular
if: always()
run: npm run build:angular
- run: npm run test:angular
- run: npm run validate:angular
- run: npm run e2e:angular
- name: Build React
if: always()
run: npm run build:react
- run: npm run test:react
- run: npm run validate:react
- run: npm run e2e:react
- name: Build Lit
if: always()
run: npm run build:lit
- run: npm run test:lit
- run: npm run validate:lit
- run: npm run e2e:lit
- name: Merge Reports
if: success() || failure() # run this step even if previous step failed
run: npm run merge-reports:examples
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
with:
files: |
${{ github.workspace }}/examples/lit/pokemon-catalog/target/component/coverage-final.json,
${{ github.workspace }}/examples/angular/pokemon-catalog/target/component/coverage-final.json,
${{ github.workspace }}/examples/angular/pokemon-catalog/target/integration/coverage-final.json,
${{ github.workspace }}/examples/react/pokemon-catalog/target/integration/coverage-final.json
verbose: true
- name: Angular Tests Report
uses: phoenix-actions/test-reporting@v8
id: test-report-angular # Set ID reference for step
if: always() # run this step even if previous step failed
with:
name: Angular Tests # Name of the check run which will be created
path: ${{ github.workspace }}/examples/angular/pokemon-catalog/cypress/results/json/merged.json # Path to test results
reporter: mochawesome-json # Format of test results
- name: React Tests Report
uses: phoenix-actions/test-reporting@v8
id: test-report-react # Set ID reference for step
if: always() # run this step even if previous step failed
with:
name: React Tests # Name of the check run which will be created
path: ${{ github.workspace }}/examples/react/pokemon-catalog/cypress/results/json/merged.json # Path to test results
reporter: mochawesome-json # Format of test results
- name: Lit Tests Report
uses: phoenix-actions/test-reporting@v8
id: test-report-lit # Set ID reference for step
if: always() # run this step even if previous step failed
with:
name: Lit Tests # Name of the check run which will be created
path: ${{ github.workspace }}/examples/lit/pokemon-catalog/cypress/results/json/merged.json # Path to test results
reporter: mochawesome-json # Format of test results