-
Notifications
You must be signed in to change notification settings - Fork 1
53 lines (44 loc) · 1.07 KB
/
test.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
name: Test
on: push
concurrency:
group: ci-${{ github.head_ref }}
cancel-in-progress: true
jobs:
test:
runs-on: ubuntu-latest
container:
image: clojure:openjdk-11-lein-2.9.6
services:
postgres:
image: "postgres:13"
env:
POSTGRES_USER: test
POSTGRES_PASSWORD: password
POSTGRES_DB: test
ports:
- 5432:5432
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
steps:
- uses: actions/checkout@v2
- name: Cache deps
uses: actions/cache@v2
with:
path: /root/.m2
key: v1-deps-${{ hashFiles('project.clj') }}
restore-keys: |
v1-deps-${{ hashFiles('project.clj') }}
- name: Install dependencies
run: lein deps
- name: Run lockjaw tests
id: tests
run: lein test 2>&1
env:
POSTGRES_USER: test
POSTGRES_PASSWORD: password
POSTGRES_HOST: postgres
POSTGRES_PORT: 5432
POSTGRES_DB: test