⬆️ Update all dependencies (major) #324
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: CI | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
branches: | |
- '*' | |
jobs: | |
build_ruby: | |
strategy: | |
matrix: | |
os: [ubuntu-22.04] | |
ruby: ['2.7', '3.0'] | |
include: | |
- os: ubuntu-22.04 | |
ruby: truffleruby-22.3.1 | |
- os: ubuntu-22.04 | |
ruby: jruby-9.4.2.0 | |
- os: macos-latest | |
ruby: '2.7' | |
- os: ubuntu-22.04 | |
ruby: '2.7' | |
- os: windows-latest | |
ruby: '2.7' | |
runs-on: ${{ matrix.os }} | |
env: | |
JRUBY_OPTS: '-J-XX:+TieredCompilation -J-XX:TieredStopAtLevel=1 -J-Xss2m -Xcompile.invokedynamic=false' | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Install Ruby | |
uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: ${{ matrix.ruby }} | |
- name: Configure Nokogiri installation (Linux) | |
if: matrix.os == 'ubuntu-22.04' | |
run: | | |
bundle config --local build__nokogiri --use-system-libraries | |
sudo apt-get install libxslt1-dev | |
- name: Configure Nokogiri installation (macOS) | |
if: matrix.os == 'macos-latest' | |
run: bundle config --local build__nokogiri --use-system-libraries | |
- name: Set JRUBY_OPTS | |
if: matrix.jruby-opts | |
run: echo 'JRUBY_OPTS=${{ matrix.jruby-opts }}' >> $GITHUB_ENV | |
- name: Install dependencies | |
run: bundle --jobs 3 --retry 3 | |
- name: Build | |
run: bundle exec rake build | |
- name: Run tests | |
run: bundle exec rake test | |
- name: Run examples:convert | |
run: bundle exec rake examples:convert | |
build_js: | |
strategy: | |
matrix: | |
os: [ubuntu-22.04] | |
node-version: ['16', '18'] | |
include: | |
- os: macos-latest | |
node-version: '16' | |
- os: windows-latest | |
node-version: '16' | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Node | |
uses: actions/setup-node@v4 | |
with: | |
node-version: ${{ matrix.node-version }} | |
- name: Install Ruby | |
uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: '2.7' | |
- name: Configure Nokogiri installation (Linux) | |
if: matrix.os == 'ubuntu-22.04' | |
run: | | |
bundle config --local build__nokogiri --use-system-libraries | |
sudo apt-get install libxslt1-dev | |
- name: Install dependencies | |
run: | | |
bundle --jobs 3 --retry 3 | |
npm ci | |
- name: Build | |
run: bundle exec rake build:js | |
- name: Run examples and tests | |
run: | | |
npm run examples | |
npm test |