mirror of
https://github.com/cpvalente/ontime.git
synced 2026-08-11 10:23:54 +00:00
a3f14182a4
* refactor: server run script * refactor: extract message control feature * refactor: socket usage for message control feature * refactor: migrate e2e testing to playwright * chore: add feature tests * refactor: add validation on socket controller * chore: jest tests server logic * chore: update tests * chore: run playwright tests on pull_requests
64 lines
1.6 KiB
YAML
64 lines
1.6 KiB
YAML
# This workflow will do a clean install of node dependencies, cache/restore them, build the source code and run tests across different versions of node
|
|
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions
|
|
|
|
name: ontime_test_CI
|
|
|
|
on: [pull_request]
|
|
|
|
jobs:
|
|
build:
|
|
|
|
runs-on: ubuntu-latest
|
|
timeout-minutes: 20
|
|
env:
|
|
CI: ''
|
|
|
|
steps:
|
|
- uses: actions/checkout@v3
|
|
- name: Use Node.js
|
|
uses: actions/setup-node@v3
|
|
with:
|
|
node-version: 16
|
|
|
|
# React
|
|
- name: React - Install dependencies
|
|
run: yarn install
|
|
working-directory: ./client
|
|
|
|
- name: React - Run tests
|
|
run: yarn test:pipeline
|
|
working-directory: ./client
|
|
|
|
- name: React - Build project
|
|
run: yarn build
|
|
working-directory: ./client
|
|
|
|
# Node server
|
|
- name: Server - Install dependencies
|
|
run: yarn install
|
|
working-directory: ./server/src
|
|
|
|
# App
|
|
- name: Electron - Install dependencies
|
|
run: yarn install && yarn setdb
|
|
working-directory: ./server
|
|
|
|
- name: Server - run tests
|
|
run: yarn test
|
|
working-directory: ./server
|
|
|
|
# - name: Install Playwright Browsers
|
|
# run: npx playwright install --with-deps
|
|
# working-directory: ./server
|
|
#
|
|
# - name: Run Playwright tests
|
|
# run: yarn e2e
|
|
# working-directory: ./server
|
|
#
|
|
# - uses: actions/upload-artifact@v3
|
|
# if: always()
|
|
# with:
|
|
# name: playwright-report
|
|
# path: playwright-report/
|
|
# retention-days: 7
|