-
Notifications
You must be signed in to change notification settings - Fork 1.3k
49 lines (46 loc) · 1.73 KB
/
windows-test.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
name: Testing on Windows
on:
push:
branches: [master]
pull_request:
branches: [master]
jobs:
test:
runs-on: ${{ matrix.os }}
continue-on-error: ${{ matrix.experimental }}
strategy:
fail-fast: false
matrix:
ruby-version: ['3.2', '3.1', '2.7']
os:
- windows-latest
experimental: [false]
include:
- ruby-version: head
os: windows-latest
experimental: true
- ruby-version: '3.0.3'
os: windows-latest
experimental: false
# On Ruby 3.0, we need to use fiddle 1.0.8 or later to retrieve correct
# error code. In addition, we have to specify the path of fiddle by RUBYLIB
# because RubyInstaller loads Ruby's bundled fiddle before initializing gem.
# See also:
# * https://github.com/ruby/fiddle/issues/72
# * https://bugs.ruby-lang.org/issues/17813
# * https://github.com/oneclick/rubyinstaller2/blob/8225034c22152d8195bc0aabc42a956c79d6c712/lib/ruby_installer/build/dll_directory.rb
ruby-lib-opt: RUBYLIB=%RUNNER_TOOL_CACHE%/Ruby/3.0.3/x64/lib/ruby/gems/3.0.0/gems/fiddle-1.1.0/lib
name: Unit testing with Ruby ${{ matrix.ruby-version }} on ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby-version }}
- name: Add Fiddle 1.1.0
if: ${{ matrix.ruby-version == '3.0.3' }}
run: gem install fiddle --version 1.1.0
- name: Install dependencies
run: ridk exec bundle install
- name: Run tests
run: bundle exec rake test TESTOPTS=-v ${{ matrix.ruby-lib-opt }}