Skip to content

Test npm package

Test npm package #18

Workflow file for this run

name: Test npm package
on:
workflow_dispatch:
schedule:
- cron: '0 0 * * 0'
jobs:
compile_works:
name: Compilation works
strategy:
matrix:
node-version:
- 18.x # LTS
- latest
os: [macos-latest, windows-latest, ubuntu-latest]
fail-fast: false
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- run: npm install --global cheerp
- run: npx cheerp clang++ test/hello.cpp -o test/hello.js
- run: node test/hello.js > test/hello.out
- run: diff test/hello.out test/hello.expected