Skip to content

Don't support macos-14. #284

Don't support macos-14.

Don't support macos-14. #284

Workflow file for this run

name: Test this action (legacy)
on:
pull_request:
push:
branches-ignore:
- legacy-v1
tags-ignore:
- '*'
paths-ignore:
- README.md
schedule:
- cron: '0 7 * * SUN'
jobs:
test:
strategy:
fail-fast: false
matrix:
# macos-14 (arm64) is currently not supported. x64 builds should work,
# but aren't freely available.
os: [ ubuntu-20.04, ubuntu-22.04, macos-12, macos-13, windows-2019, windows-2022 ]
ruby: [ '1.8.7', '1.9.3', '2.0', jruby-1.7, jruby-9.0 ]
architecture: [ default ]
exclude:
- os: ubuntu-22.04
ruby: '1.8.7'
architecture: default
- os: macos-12
ruby: '1.8.7'
architecture: default
- os: macos-13
ruby: '1.8.7'
architecture: default
- os: windows-2019
ruby: '1.8.7'
architecture: default
- os: windows-2022
ruby: '1.8.7'
architecture: default
include:
- os: windows-2019
ruby: '2.0'
architecture: x86
- os: windows-2019
ruby: '2.0'
architecture: x64
- os: windows-2022
ruby: '2.0'
architecture: x86
- os: windows-2022
ruby: '2.0'
architecture: x64
name: ${{ matrix.os }} ${{ matrix.ruby }} (${{matrix.architecture}})
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
- uses: ./
with:
ruby-version: ${{ matrix.ruby }}
architecture: ${{ matrix.architecture }}
bundler-cache: true
- run: ruby -v
- name: PATH
shell: bash
run: echo $PATH
- name: build compiler
run: |
ruby -rrbconfig -e "puts 'build compiler: ' + RbConfig::CONFIG.fetch('CC_VERSION_MESSAGE', 'unknown').lines.first"
- name: gcc and ridk version (mingw)
if: startsWith(matrix.os, 'windows')
run: |
$abi, $plat = $(ruby -rrbconfig -e "STDOUT.write RbConfig::CONFIG['ruby_version'] + ' ' + RUBY_PLATFORM").split(' ')
if ($plat.Contains('mingw')) {
gcc --version
if ($abi -ge '2.4') {
ridk version
} else {
echo 'ridk is unavailable'
}
}
- name: RbConfig::CONFIG
run: ruby -rrbconfig -rpp -e 'pp RbConfig::CONFIG'
- name: RbConfig::MAKEFILE_CONFIG
run: ruby -rrbconfig -rpp -e 'pp RbConfig::MAKEFILE_CONFIG'
- name: Subprocess test
run: ruby test_subprocess.rb
- name: OpenSSL version
run: ruby -ropenssl -e 'puts OpenSSL::OPENSSL_LIBRARY_VERSION if OpenSSL.const_defined?(:OPENSSL_LIBRARY_VERSION)'
- name: OpenSSL test
run: ruby -ropen-uri -e 'puts URI.send(:open, %{https://rubygems.org/}) { |f| f.read(1024) }'
- id: gemoptions
run: |
if gem help install | grep -q no-document; then
echo 'gemoptions=--no-document' >> $GITHUB_OUTPUT
else
echo 'gemoptions=--no-rdoc --no-ri' >> $GITHUB_OUTPUT
fi
shell: bash
- name: C extension test
run: gem install json -v 1.8.6 ${{ steps.gemoptions.outputs.gemoptions }}
- run: bundle --version
# This step is redundant with `bundler-cache: true` but is there to check a redundant `bundle install` still works
- run: bundle install
- run: bundle exec rake --version
- name: which ruby, rake
if: "!startsWith(matrix.os, 'windows')"
run: which -a ruby rake
- name: where ruby, rake
if: startsWith(matrix.os, 'windows')
run: |
$ErrorActionPreference = 'Continue'
$where = 'ruby', 'rake'
foreach ($e in $where) {
$rslt = where.exe $e 2>&1 | Out-String
if ($rslt.contains($e)) { echo $rslt.Trim() }
else { echo "Can't find $e" }
echo ''
}
- name: bash test
shell: bash
run: echo ~
testExactBundlerVersion:
name: "Test with an exact Bundler version"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: ./
with:
ruby-version: 2.0
bundler: 1.17.3
- run: bundle --version | grep -F "Bundler version 1.17.3"
testDependencyOnBundler1:
name: "Test gemfile depending on Bundler 1"
runs-on: ubuntu-latest
env:
BUNDLE_GEMFILE: gemfiles/bundler1.gemfile
steps:
- uses: actions/checkout@v3
- uses: ./
with:
ruby-version: 2.0
bundler: 1
bundler-cache: true
- run: bundle --version | grep -F "Bundler version 1."
testGemfileMatrix:
strategy:
fail-fast: false
matrix:
gemfile: [ rails4 ]
name: "Test with ${{ matrix.gemfile }} gemfile"
runs-on: ubuntu-latest
env:
BUNDLE_GEMFILE: gemfiles/${{ matrix.gemfile }}.gemfile
steps:
- uses: actions/checkout@v3
- uses: ./
with:
ruby-version: 2.0
bundler-cache: true
- run: bundle exec rails --version
lint:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
- run: yarn install
- run: yarn run package
- name: Check generated files are up to date
run: git diff --exit-code