-
Notifications
You must be signed in to change notification settings - Fork 65
112 lines (107 loc) · 2.71 KB
/
ci.yml
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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
name: Vimgolf CI
on:
- push
- pull_request
jobs:
rubocop:
runs-on: ubuntu-latest
steps:
- name: Check out git tree
uses: actions/checkout@v2
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
bundler-cache: true
- name: Run rubocop
run: bundle exec rubocop
rspec-rails:
runs-on: ubuntu-latest
env:
FERRUM_PROCESS_TIMEOUT: 30
steps:
- name: Check out git tree
uses: actions/checkout@v2
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
bundler-cache: true
- name: Run RSpec tests
run: bundle exec rake
- name: Upload coverage information
uses: codecov/[email protected]
with:
files: ./coverage/coverage.xml
rspec-rails-macos:
runs-on: macos-latest
env:
FERRUM_PROCESS_TIMEOUT: 30
steps:
- name: Check out git tree
uses: actions/checkout@v2
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
bundler-cache: true
cache-version: 1
- name: Run RSpec tests
run: bundle exec rake
rspec-rails-pg:
runs-on: ubuntu-18.04
services:
postgres:
image: postgres:latest
env:
POSTGRES_USER: vimgolfgh
POSTGRES_PASSWORD: vimgolfpw
ports:
- 5432:5432
env:
DATABASE_ADAPTER: pg
DATABASE_URL: postgresql://vimgolfgh:vimgolfpw@localhost/
FERRUM_PROCESS_TIMEOUT: 30
steps:
- name: Check out git tree
uses: actions/checkout@v2
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
bundler-cache: true
- name: Create database
run: bundle exec rails db:create db:migrate RAILS_ENV=test
- name: Run RSpec tests
run: bundle exec rake
rspec-client-gem:
strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest
- macos-latest
ruby-version:
- '2.3'
- '2.4'
- '2.7'
- '3.0'
include:
- os: ubuntu-latest
ruby-version: '2.1'
- os: ubuntu-latest
ruby-version: '2.0'
- os: macos-latest
ruby-version: '2.0'
- os: windows-latest
ruby-version: '2.7'
runs-on: ${{ matrix.os }}
steps:
- name: Check out git tree
uses: actions/checkout@v2
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby-version }}
bundler-cache: true
env:
BUNDLE_GEMFILE: lib/vimgolf/Gemfile
- name: Run RSpec tests
working-directory: lib/vimgolf
run: bundle exec rake