Skip to content

test: add -Infinity double test cases #196

test: add -Infinity double test cases

test: add -Infinity double test cases #196

Workflow file for this run

name: CI
on:
push:
branches: [ master, 1.x ]
pull_request:
branches: [ master, 1.x ]
jobs:
Job:
name: Node.js
uses: node-modules/github-actions/.github/workflows/node-test.yml@master
with:
os: 'ubuntu-latest'
version: '8, 10, 12, 14, 16, 18, 20, 22'
secrets:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
build-with-zig:
strategy:
fail-fast: false
matrix:
targets:
[
'x86_64-unknown-linux-gnu',
'aarch64-unknown-linux-gnu'
]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true
target: ${{ matrix.targets }}
- uses: Swatinem/rust-cache@v2
- uses: actions/setup-node@v3
with:
node-version: '16'
- name: Install ziglang
uses: goto-bus-stop/setup-zig@v1
with:
version: 0.10.0
- run: npm install
- run: rustup toolchain install nightly-2022-12-12
- run: rustup target add --toolchain nightly-2022-12-12 ${{ matrix.targets }}
- run: (cd ./lib/v2rust && cargo test -- --nocapture --test-threads=1)
- run: npx napi build --cargo-cwd ./lib/v2rust --platform --release ./lib/v2rust/harness/dist/ --zig --zig-abi-suffix 2.17 --target ${{ matrix.targets }}
- uses: actions/upload-artifact@v3
with:
name: bindings-${{ matrix.targets }}
path: lib/v2rust/harness/dist/
if-no-files-found: error
build:
strategy:
fail-fast: false
matrix:
targets:
[
'x86_64-pc-windows-msvc',
'aarch64-pc-windows-msvc',
'x86_64-apple-darwin',
'aarch64-apple-darwin'
]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true
target: ${{ matrix.targets }}
- uses: Swatinem/rust-cache@v2
- uses: actions/setup-node@v3
with:
node-version: '16'
- name: Install ziglang
uses: goto-bus-stop/setup-zig@v1
with:
version: 0.10.0
- run: cargo install cargo-xwin
- run: npm install
- run: rustup toolchain install nightly-2022-12-12
- run: rustup target add --toolchain nightly-2022-12-12 ${{ matrix.targets }}
- run: (cd ./lib/v2rust && cargo test -- --nocapture --test-threads=1)
- run: npx napi build --cargo-cwd ./lib/v2rust --platform --release ./lib/v2rust/harness/dist/ --target ${{ matrix.targets }}
- uses: actions/upload-artifact@v3
with:
name: bindings-${{ matrix.targets }}
path: lib/v2rust/harness/dist/
if-no-files-found: error
test-rust-v2:
strategy:
fail-fast: false
matrix:
settings:
- target: x86_64-unknown-linux-gnu
docker: node:18-slim
setup: 'exit 0'
runs-on: ubuntu-latest
needs:
- build-with-zig
steps:
- run: docker run --rm --privileged multiarch/qemu-user-static:register --reset
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node }}
- name: Install dependencies
run: npm install
- name: Download bindings
uses: actions/download-artifact@v3
with:
name: bindings-${{ matrix.settings.target }}
path: lib/v2rust/harness/dist/
- name: Run tests
uses: addnab/docker-run-action@v3
with:
image: ${{ matrix.settings.docker }}
options: -v ${{ github.workspace }}:/build -w /build
run: |
set -e ${{ matrix.settings.setup }}
apt update
apt install make
make test-v2rust