This repository has been archived by the owner on Nov 4, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 6
69 lines (57 loc) · 1.93 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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
name: Omnia Tests
on:
workflow_dispatch: # Allow manual trigger only. We have manually controll execution phase
pull_request:
branches:
- master
- develop
push:
branches:
- master
- develop
jobs:
unit-test:
name: Unit Tests
runs-on: ubuntu-latest
env:
COMPOSE_FILE: .github/docker-compose-unit-tests.yml
DOCKER_BUILDKIT: 1
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Login to Github Packages
uses: docker/login-action@v1
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: PreBuild Omnia images (Used by omnia/tests/e2e/Dockerfile)
run: docker build -t ghcr.io/chronicleprotocol/omnia_relay:dev -f omnia/Dockerfile .
- name: Run Unit Tests
run: docker-compose -f $COMPOSE_FILE run --rm omnia_unit_tests
test-e2e:
name: E2E tests
needs: unit-test
runs-on: ubuntu-latest
env:
COMPOSE_FILE: .github/docker-compose-e2e-tests.yml
DOCKER_BUILDKIT: 1
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Login to Github Packages
uses: docker/login-action@v1
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: PreBuild Omnia images (Used by omnia/tests/e2e/Dockerfile)
run: docker build -t ghcr.io/chronicleprotocol/omnia_relay:dev -f omnia/Dockerfile .
- name: Building Omnia e2e image
run: docker-compose -f $COMPOSE_FILE build omnia_e2e
- name: Running Omnia Feed E2E tests
run: docker-compose -f $COMPOSE_FILE run --rm omnia_e2e go test -v -parallel 1 -cpu 1 -p 1 ./relay