-
Notifications
You must be signed in to change notification settings - Fork 12
51 lines (43 loc) · 1.24 KB
/
Copy pathruby.yml
File metadata and controls
51 lines (43 loc) · 1.24 KB
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
name: Ruby
on:
push:
branches: [ '*' ]
pull_request:
branches: [ '*' ]
permissions:
contents: read
jobs:
test:
runs-on: ubuntu-latest
services:
postgres:
image: postgres:latest
env:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_HOST: localhost
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
- 5432:5432
steps:
- name: Setup system dependencies
run: sudo apt-get install -y libpq-dev postgresql-server-dev-16
# https://github.com/actions/checkout
- uses: actions/checkout@v6
- name: Set up Ruby
# To automatically get bug fixes and new Ruby versions for ruby/setup-ruby,
# use ruby/setup-ruby@v1. See https://github.com/ruby/setup-ruby
uses: ruby/setup-ruby@v1
with:
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
- name: Run tests
run: bundle exec rake spec
env:
JUNETHACK_POSTGRES_USER: postgres
JUNETHACK_POSTGRES_PASSWORD: postgres
JUNETHACK_POSTGRES_HOST: localhost
JUNETHACK_POSTGRES_DATABASE: postgres