Skip to content

Commit 7c94a03

Browse files
authored
Travis -> GHA (#2)
* Travis -> GHA * Fix tmpdir
1 parent 07f16d4 commit 7c94a03

File tree

3 files changed

+48
-10
lines changed

3 files changed

+48
-10
lines changed

.github/workflows/test.yml

+47
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
name: Tests
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- main
7+
- master
8+
push:
9+
branches:
10+
- main
11+
- master
12+
13+
jobs:
14+
test:
15+
name: Test Ruby ${{ matrix.RUBY_VERSION }}
16+
runs-on: ubuntu-20.04
17+
strategy:
18+
fail-fast: false
19+
matrix:
20+
RUBY_VERSION: ["2.0", "2.1", "2.2", "2.3", "3.0"]
21+
steps:
22+
- name: Check out code
23+
uses: actions/checkout@v4
24+
25+
- name: Install Ruby
26+
uses: ruby/setup-ruby@v1
27+
with:
28+
ruby-version: ${{ matrix.RUBY_VERSION }}
29+
bundler-cache: true
30+
bundler: 1.13.6
31+
32+
- name: Run Tests
33+
run: bundle exec rake
34+
35+
results:
36+
if: ${{ always() }}
37+
runs-on: ubuntu-latest
38+
name: Final Results
39+
needs: [test]
40+
steps:
41+
- run: exit 1
42+
# see https://stackoverflow.com/a/67532120/4907315
43+
if: >-
44+
${{
45+
contains(needs.*.result, 'failure')
46+
|| contains(needs.*.result, 'cancelled')
47+
}}

.travis.yml

-10
This file was deleted.

spec/spawn_passthrough_spec.rb

+1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
require 'spec_helper'
2+
require 'tmpdir'
23

34
describe SpawnPassthrough do
45
it 'has a version number' do

0 commit comments

Comments
 (0)