Skip to content

Update deps

Update deps #56

Workflow file for this run

name: ci
on: [push, pull_request]
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [16, 18, 20]
target: [test, stress, multi, disruptor, remote, coverage]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Update APT
run: sudo apt update
- name: Install OS dependencies
run: sudo apt install socat
- name: Use Node.js
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- name: Setup SSH
run: |
ssh-keygen -t rsa -f ~/.ssh/id_rsa -N ''
cat ~/.ssh/id_rsa.pub >> ~/.ssh/authorized_keys
ssh-keyscan -t rsa localhost >> ~/.ssh/known_hosts
chmod 600 ~/.ssh/*
chmod 700 ~/.ssh
chmod 755 ~/
- name: Check versions
run: |
test "$(node --version | cut -d . -f 1)" = "v${{ matrix.node-version }}"
echo "PATH=\"$(dirname "$(which node)"):\$PATH\"" > ~/.bashrc.new
cat ~/.bashrc >> ~/.bashrc.new
mv ~/.bashrc.new ~/.bashrc
node_ver="$(ssh localhost node --version)"
echo "Node $node_ver"
test "$(echo "$node_ver" | cut -d . -f 1)" = "v${{ matrix.node-version }}"
- name: Install packages
run: npm install
- name: Run tests
run: npm run ${{ matrix.target }}
- name: Coveralls
if: matrix.target == 'coverage'
uses: coverallsapp/github-action@v2
with:
github-token: ${{ secrets.GITHUB_TOKEN }}