Skip to content

Add linux arm64 docker test #107

Add linux arm64 docker test

Add linux arm64 docker test #107

name: Test Install & Import
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
test:
strategy:
fail-fast: false
matrix:
node: ['14', '16', '18', '20']
os: [macos-latest, windows-latest, ubuntu-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
- name: Setup node ${{ matrix.node }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node }}
- name: NPM Pack
run: npm pack
- name: Rename Package
run: mv faiss-node-*.tgz faiss-node.tgz
- name: NPM Install
working-directory: ./test-import
run: npm install ../faiss-node.tgz --verbose
- name: Test
working-directory: ./test-import
run: npm test
- name: Uninstall libomp
if: matrix.os == 'macos-latest'
run: brew uninstall --ignore-dependencies libomp
- name: Test without libomp
if: matrix.os == 'macos-latest'
working-directory: ./test-import
run: npm test
- name: Install libomp
if: matrix.os == 'macos-latest'
run: brew install libomp
- name: Test with libomp installed
if: matrix.os == 'macos-latest'
working-directory: ./test-import
run: npm test