1
0
Fork 0
mirror of https://github.com/puma/puma.git synced 2022-11-09 13:48:40 -05:00
puma--puma/.github/workflows/ruby.yml

137 lines
3.3 KiB
YAML
Raw Normal View History

2019-09-19 13:50:13 -04:00
name: Puma
on: [push, pull_request]
2019-09-19 13:50:13 -04:00
jobs:
build:
name: >-
2020-02-13 11:47:15 -05:00
${{ matrix.os }}, ${{ matrix.ruby }}
env:
CI: true
TESTOPTS: -v
2019-09-19 13:50:13 -04:00
runs-on: ${{ matrix.os }}
if: |
!(contains(github.event.pull_request.title, '[ci skip]')
|| contains(github.event.head_commit.message, '[ci skip]'))
2019-09-19 13:50:13 -04:00
strategy:
fail-fast: false
matrix:
2020-02-13 11:47:15 -05:00
os: [ ubuntu-18.04, macos ]
ruby: [ 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, head, jruby, truffleruby-head ]
2019-09-19 13:50:13 -04:00
steps:
2020-02-13 11:47:15 -05:00
- name: repo checkout
uses: actions/checkout@v2
- name: load ruby, ragel
uses: MSP-Greg/setup-ruby-pkgs@v1
2020-02-13 11:47:15 -05:00
with:
ruby-version: ${{ matrix.ruby }}
apt-get: ragel
brew: ragel
2020-02-13 11:47:15 -05:00
- name: bundle install
2020-02-13 11:47:15 -05:00
run: |
# update RubyGems in Ruby 2.2, bundle install
if [[ "${{ matrix.ruby }}" < "2.3" ]]; then
gem update --system 2.7.10 --no-document
2020-02-13 11:47:15 -05:00
fi
bundle install --jobs 4 --retry 3 --path=.bundle/puma
2020-02-13 11:47:15 -05:00
- name: compile
run: bundle exec rake compile
- name: rubocop
if: startsWith(matrix.ruby, '2.')
run: bundle exec rake rubocop
- name: test
timeout-minutes: 8
run: bundle exec rake test:all
2020-02-13 11:47:15 -05:00
win32:
name: >-
${{ matrix.os }}, ${{ matrix.ruby }}
env:
CI: true
TESTOPTS: -v
runs-on: ${{ matrix.os }}
if: |
!(contains(github.event.pull_request.title, '[ci skip]')
|| contains(github.event.head_commit.message, '[ci skip]'))
2020-02-13 11:47:15 -05:00
strategy:
fail-fast: false
matrix:
os: [ windows-latest ]
ruby: [ 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, mingw ]
2020-02-13 11:47:15 -05:00
steps:
- name: repo checkout
uses: actions/checkout@v2
- name: load ruby, ragel, openssl
uses: MSP-Greg/setup-ruby-pkgs@v1
2020-02-13 11:47:15 -05:00
with:
ruby-version: ${{ matrix.ruby }}
mingw: _upgrade_ openssl ragel
2020-02-13 11:47:15 -05:00
- name: bundle install
run: |
# update RubyGems in Ruby 2.2, bundle install
if ('${{ matrix.ruby }}' -lt '2.3') {
gem update --system 2.7.10 --no-document
}
bundle install --jobs 4 --retry 3 --path=.bundle/puma
2020-02-13 11:47:15 -05:00
- name: compile
run: |
bundle exec rake compile
- name: test
timeout-minutes: 8
run: bundle exec rake
allowedFailures:
name: >-
${{ matrix.cfg.os }}, ${{ matrix.cfg.ruby }}
env:
CI: true
TESTOPTS: -v
runs-on: ${{ matrix.cfg.os }}
if: |
!(contains(github.event.pull_request.title, '[ci skip]')
|| contains(github.event.head_commit.message, '[ci skip]'))
strategy:
fail-fast: false
matrix:
cfg:
- { os: ubuntu-latest, ruby: jruby-head }
steps:
- name: repo checkout
uses: actions/checkout@v2
- name: load ruby, ragel
uses: MSP-Greg/setup-ruby-pkgs@v1
with:
ruby-version: ${{ matrix.cfg.ruby }}
apt-get: ragel
brew: ragel
- name: bundle install
run: |
bundle install --jobs 4 --retry 3 --path=.bundle/puma
- name: compile
continue-on-error: true
run: bundle exec rake compile
- name: test
timeout-minutes: 8
continue-on-error: true
if: success()
run: bundle exec rake