forked from catalystdao/generalised-relayer
-
Notifications
You must be signed in to change notification settings - Fork 0
51 lines (42 loc) · 1.06 KB
/
tests.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
name: Run pnpm tests with Redis
on:
push:
branches:
- 'testnet'
tags:
- 'v*'
pull_request:
branches:
- 'testnet'
jobs:
test:
name: Run pnpm tests inside Docker with Redis
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
attempt: [1, 2, 3]
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Start Redis container
run: |
echo "Installing Foundry and anvil"
curl -L https://foundry.paradigm.xyz | bash
foundryup
- name: Run tests inside Docker container
run: |
docker run --rm --network="host" \
-e REDIS_HOST=127.0.0.1 \
-e REDIS_PORT=6379 \
relayer-test-image
- name: Check Test Results
if: ${{ failure() && matrix.attempt != '3' }}
run: exit 1
- name: Stop and remove Redis container
if: always()
run: |
docker stop redis-test-container
docker rm redis-test-container