Skip to content

SUPINT-2380: nuxeo admin console web scripts works #36

SUPINT-2380: nuxeo admin console web scripts works

SUPINT-2380: nuxeo admin console web scripts works #36

Workflow file for this run

name: Unit-test
on:
pull_request:
branches:
- dev
workflow_call:
inputs:
branch:
description: 'The current branch'
default: dev
type: string
required: false
env:
BRANCH_NAME: ${{ github.head_ref || inputs.branch || 'dev' }}
jobs:
utest:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
ref: ${{ env.BRANCH_NAME }}
- name: Remove .npmrc file if exists
run: |
if [ -f .npmrc ]; then
rm .npmrc
fi
- uses: actions/setup-node@v4
with:
registry-url: 'https://packages.nuxeo.com/repository/npm-public/'
node-version: 20
scope: '@nuxeo'
- name: Configure Additional Registries
run: |
npm config set @hylandsoftware:registry https://npm.pkg.github.com --global
npm config set //npm.pkg.github.com/:_authToken=${{ secrets.GIT_TOKEN }} --global
npm config set registry https://registry.npmjs.org/ --global
- name: Install @angular/cli
run: npm install -g @angular/cli
- name: Install Dependencies
working-directory: ./nuxeo-admin-console-ui/nuxeo-admin-console-web/ang-src
run: npm install
- name: Install Chrome and Chromedriver
uses: browser-actions/setup-chrome@v1
with:
chrome-version: 120
install-chromedriver: true
- name: Verify Chrome installation
run: google-chrome --version
- name: Unit tests
working-directory: ./nuxeo-admin-console-ui/nuxeo-admin-console-web/ang-src
run: |
xvfb-run --auto-servernum --server-args="-screen 0 1024x768x24" npm test