Update CI #149
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Ruby | |
on: | |
push: | |
branches: [ master ] | |
pull_request: | |
branches: [ master ] | |
jobs: | |
run-tests: | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [ubuntu-latest, macos-latest] | |
# Due to https://github.com/actions/runner/issues/849, we have to use quotes for '3.0' | |
ruby: ['3.0', '3.1', '3.2', '3.3', head, jruby, jruby-head, truffleruby, truffleruby-head] | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Prepare Linux | |
if: contains(matrix.os, 'ubuntu') | |
run: | | |
sudo apt-get update -y | |
sudo apt-get install git libfontconfig1-dev libsndfile1-dev libsdl2-dev libmpg123-dev libopenal1 libopenal-dev | |
- name: Prepare macOS | |
if: contains(matrix.os, 'macOS') | |
run: | | |
brew update || true | |
brew install pkg-config sdl2 || true | |
sudo rm -rf /Library/Developer/CommandLineTools | |
- uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: ${{ matrix.ruby }} | |
bundler-cache: true # runs 'bundle install' and caches installed gems automatically | |
- name: Build and test with rspec | |
run: | | |
bundle exec rspec |