chore(deps-dev): bump electron-to-chromium from 1.4.475 to 1.4.490 (#… #2411
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
# For details of what checks are run for PRs please refer below | |
# docs: https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions | |
name: Node CI | |
on: | |
push: | |
branches: [ 'main', 'master', '1.0-dev' ] | |
pull_request: | |
workflow_dispatch: | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
env: | |
DIST_DIR: dist | |
REPORTS_DIR: reports | |
NODE_ACTIVE_LTS: '20' # https://nodejs.org/en/about/releases/ | |
jobs: | |
build: | |
name: build | |
runs-on: 'ubuntu-latest' | |
timeout-minutes: 10 | |
steps: | |
- name: Checkout | |
# see https://github.com/actions/checkout | |
uses: actions/checkout@v3 | |
- name: Setup Node.js ${{ env.NODE_ACTIVE_LTS }} | |
# see https://github.com/actions/setup-node | |
uses: actions/setup-node@v3 | |
with: | |
node-version: ${{ env.NODE_ACTIVE_LTS }} | |
cache: 'npm' | |
- name: setup subject | |
run: npm ci --ignore-scripts --loglevel=silly | |
- name: build | |
run: npm run build | |
- name: artifact build result | |
# see https://github.com/actions/upload-artifact | |
uses: actions/upload-artifact@v3 | |
with: | |
name: ${{ env.DIST_DIR }} | |
path: ${{ env.DIST_DIR }} | |
if-no-files-found: error | |
test-standards: | |
name: test standards | |
timeout-minutes: 30 | |
runs-on: 'ubuntu-latest' | |
steps: | |
- name: Checkout | |
# see https://github.com/actions/checkout | |
uses: actions/checkout@v3 | |
- name: Setup Node.js ${{ env.NODE_ACTIVE_LTS }} | |
# see https://github.com/actions/setup-node | |
uses: actions/setup-node@v3 | |
with: | |
node-version: ${{ env.NODE_ACTIVE_LTS }} | |
cache: 'npm' | |
- name: install subject | |
run: npm ci --loglevel=silly | |
- name: run tests | |
run: npm run test:standard | |
test-jest: | |
needs: [ 'build' ] | |
name: jest (node${{ matrix.node-version }} ${{ matrix.os }}) | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
node-version: | |
## action based on https://github.com/actions/node-versions/releases | |
## see also: https://nodejs.org/en/about/releases/ | |
- '20' # Current | |
- '18' # Active LTS | |
- '16' | |
- '14' | |
os: | |
- ubuntu-latest | |
- windows-latest | |
- macos-latest | |
timeout-minutes: 10 | |
steps: | |
- name: Checkout | |
# see https://github.com/actions/checkout | |
uses: actions/checkout@v3 | |
- name: Setup Node.js ${{ matrix.node-version }} | |
# see https://github.com/actions/setup-node | |
uses: actions/setup-node@v3 | |
with: | |
node-version: ${{ matrix.node-version }} | |
cache: 'npm' | |
- name: setup subject | |
shell: bash | |
run: | | |
set -ex | |
npm ci --ignore-scripts --loglevel=silly | |
## rebuild deps for which scripts were ignored, or partially installed - since "ignore-scripts" was used | |
npm rebuild --loglevel=silly libxmljs2 || npm uninstall --no-save libxmljs2 | |
- name: fetch build artifact | |
# see https://github.com/actions/download-artifact | |
uses: actions/download-artifact@v3 | |
with: | |
name: ${{ env.DIST_DIR }} | |
path: ${{ env.DIST_DIR }} | |
- name: test | |
run: > | |
npm run test:jest -- | |
--ci | |
--verbose | |
--runInBand | |
--logHeapUsage | |
- name: artifact test logs | |
if: ${{ failure() }} | |
# see https://github.com/actions/upload-artifact | |
uses: actions/upload-artifact@v3 | |
with: | |
name: logs-jest_node${{ matrix.node-version }}-${{ matrix.os }} | |
path: tests/_log | |
if-no-files-found: error | |
- name: artifact test reports | |
if: ${{ failure() }} | |
# see https://github.com/actions/upload-artifact | |
uses: actions/upload-artifact@v3 | |
with: | |
name: reports-jest_node${{ matrix.node-version }}-${{ matrix.os }} | |
path: ${{ env.REPORTS_DIR }} | |
if-no-files-found: error | |
dogfooding-direct: | |
needs: [ 'build' ] | |
name: dogfooding/direct (node${{ matrix.node-version }} ${{ matrix.os }}) | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
node-version: | |
## action based on https://github.com/actions/node-versions/releases | |
## see also: https://nodejs.org/en/about/releases/ | |
- '20' # Current | |
- '18' # Active LTS | |
- '16' | |
- '14' | |
os: | |
- ubuntu-latest | |
- windows-latest | |
- macos-latest | |
timeout-minutes: 10 | |
steps: | |
- name: Checkout | |
# see https://github.com/actions/checkout | |
uses: actions/checkout@v3 | |
- run: mkdir -p ${{ env.REPORTS_DIR }} | |
- name: Setup Node.js ${{ matrix.node-version }} | |
# see https://github.com/actions/setup-node | |
uses: actions/setup-node@v3 | |
with: | |
node-version: ${{ matrix.node-version }} | |
cache: 'npm' | |
- name: setup subject | |
shell: bash | |
run: | | |
set -ex | |
npm ci --ignore-scripts --omit=dev --loglevel=silly | |
## rebuild deps for which scripts were ignored, or partially installed - since "ignore-scripts" was used | |
npm rebuild --loglevel=silly libxmljs2 || npm uninstall --no-save libxmljs2 | |
- name: fetch build artifact | |
# see https://github.com/actions/download-artifact | |
uses: actions/download-artifact@v3 | |
with: | |
name: ${{ env.DIST_DIR }} | |
path: ${{ env.DIST_DIR }} | |
- name: dogfooding | |
run: > | |
node -- bin/cyclonedx-npm-cli.js | |
--ignore-npm-errors | |
--omit=dev | |
--validate | |
--output-file=${{ env.REPORTS_DIR }}/bom.json | |
- name: artifact test reports | |
if: ${{ failure() }} | |
# see https://github.com/actions/upload-artifact | |
uses: actions/upload-artifact@v3 | |
with: | |
name: dogfooding-direct_node${{ matrix.node-version }}-${{ matrix.os }} | |
path: ${{ env.REPORTS_DIR }} | |
if-no-files-found: error |