-
Notifications
You must be signed in to change notification settings - Fork 0
53 lines (47 loc) · 1.28 KB
/
run_e2e_tests.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
50
51
52
53
name: E2E Tests
on: [pull_request]
jobs:
e2e-test:
name: E2E Tests
strategy:
matrix:
go-version: ['1.20']
os: [ubuntu-latest]
runs-on: ${{ matrix.os }}
services:
postgres:
image: postgres:15.4
# Set Postgres db, user, password
env:
POSTGRES_DB: public
POSTGRES_USER: user
POSTGRES_PASSWORD: password
# Set health checks to wait until postgres has started
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
# Maps tcp port 5432 on service container to the host
- 5432:5432
redis:
image: redis:6.2.6
# Set health checks to wait until redis has started
options: >-
--health-cmd "redis-cli ping"
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
# Maps tcp port 6379 on service container to the host
- 6379:6379
steps:
- name: Install Go
uses: actions/setup-go@v2
with:
go-version: ${{ matrix.go-version }}
- name: Checkout code
uses: actions/checkout@v2
- name: E2E Tests
run: make e2e-test