blob: aea0ee98dce2ccd9dee005e3b9064dbb078058a0 [file] [log] [blame]
name: Unit test library methods
on:
push:
paths:
- '**/unittestlib.yml'
- 'lib/**'
workflow_dispatch:
permissions: # added using https://github.com/step-security/secure-workflows
contents: read
jobs:
test:
strategy:
fail-fast: false
matrix:
os: [macos-latest, ubuntu-20.04, ubuntu-22.04]
ruby: [2.7, 3.1]
# 2.7 not supported on 22.04
exclude:
- os: ubuntu-22.04
ruby: 2.7
runs-on: ${{ matrix.os }}
steps:
- name: setup # needed for installing ruby-ldap
run: |
sudo apt-get update
sudo apt-get install libldap2-dev
sudo apt-get install libsasl2-dev
sudo apt-get install libyaml-dev # seems to be needed for installing ruby since psych 5.0.0 release
if: matrix.os != 'macos-latest'
- uses: actions/checkout@v3
with:
persist-credentials: false
- name: ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
bundler-cache: true
- name: test library code
run: |
cd lib
bundle install
bundle exec rake