Remove Jest #250
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: Release | |
on: | |
push: | |
branches: | |
- master | |
- release/* | |
jobs: | |
lint-test-build: | |
name: Lint, Unit Test and Build | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Read .node-version | |
id: node-version | |
uses: juliangruber/read-file-action@v1 | |
with: | |
path: ./.node-version | |
- name: Use Node.js ${{ steps.node-version.outputs.content }} | |
uses: actions/setup-node@v2 | |
with: | |
node-version: ${{ steps.node-version.outputs.content }} | |
cache: 'npm' | |
- name: Install | |
run: npm ci | |
- name: Lint | |
run: npm run lint | |
- name: Generate | |
run: npm run generate | |
- uses: actions/upload-artifact@v2 | |
with: | |
name: dist | |
path: dist | |
if-no-files-found: error | |
test-e2e: | |
name: E2E Test | |
needs: lint-test-build | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
browser: [chrome, firefox, edge] | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Read .node-version | |
id: node-version | |
uses: juliangruber/read-file-action@v1 | |
with: | |
path: ./.node-version | |
- name: Use Node.js ${{ steps.node-version.outputs.content }} | |
uses: actions/setup-node@v2 | |
with: | |
node-version: ${{ steps.node-version.outputs.content }} | |
cache: 'npm' | |
- name: Download Artifact | |
uses: actions/download-artifact@master | |
with: | |
name: dist | |
path: dist | |
- name: E2E by Cypress | |
uses: cypress-io/github-action@v2 | |
with: | |
browser: ${{ matrix.browser }} | |
command: npm run e2e:ci | |
- uses: actions/upload-artifact@v2 | |
if: failure() | |
with: | |
name: cypress-${{ matrix.browser }} | |
path: | | |
cypress/videos | |
cypress/screenshots | |
deploy: | |
name: Deploy | |
needs: test-e2e | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
node-version: [14.16.0] | |
steps: | |
- uses: actions/checkout@master | |
- name: Use Node.js ${{ matrix.node-version }} | |
uses: actions/setup-node@master | |
with: | |
node-version: ${{ matrix.node-version }} | |
cache: 'npm' | |
- name: Download Artifact | |
uses: actions/download-artifact@master | |
with: | |
name: dist | |
path: dist | |
- name: Deploy to Firebase | |
uses: w9jds/firebase-action@master | |
with: | |
args: deploy --only hosting | |
env: | |
FIREBASE_TOKEN: ${{ secrets.FIREBASE_TOKEN }} |