-
Notifications
You must be signed in to change notification settings - Fork 3
68 lines (65 loc) · 2.12 KB
/
ccip-integration-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
name: "Run CCIP OCR3 Integration Test"
on:
pull_request:
push:
branches:
- 'ccip-develop'
jobs:
integration-test-ccip-ocr3:
env:
# We explicitly have this env var not be "CL_DATABASE_URL" to avoid having it be used by core related tests
# when they should not be using it, while still allowing us to DRY up the setup
DB_URL: postgresql://postgres:postgres@localhost:5432/chainlink_test?sslmode=disable
runs-on: ubuntu-latest
strategy:
matrix:
go-version: ['1.22.5']
steps:
- name: Checkout the repo
uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 # v4.1.2
- name: Setup Go ${{ matrix.go-version }}
uses: actions/setup-go@0c52d547c9bc32b1aa3301fd7a9cb496313a4491 # v5.0.0
with:
go-version: ${{ matrix.go-version }}
- name: Display Go version
run: go version
- name: Clone CCIP repo
run: |
git clone https://github.com/smartcontractkit/ccip.git
cd ccip
git fetch
git checkout ccip-develop
- name: Update chainlink-ccip dependency in ccip
run: |
cd ccip
go get github.com/smartcontractkit/chainlink-ccip@${{ github.sha }}
make gomodtidy
- name: Setup Postgres
uses: ./.github/actions/setup-postgres
- name: Download Go vendor packages
run: |
cd ccip
go mod download
- name: Build binary
run: |
cd ccip
go build -o ccip.test .
- name: Setup DB
run: |
cd ccip
./ccip.test local db preparetest
env:
CL_DATABASE_URL: ${{ env.DB_URL }}
- name: Run ccip ocr3 integration test
run: |
cd ccip
go test -v -timeout 3m -run "^TestIntegration_OCR3Nodes$" ./core/capabilities/ccip/ccip_integration_tests
EXITCODE=${PIPESTATUS[0]}
if [ $EXITCODE -ne 0 ]; then
echo "Integration test failed"
else
echo "Integration test passed!"
fi
exit $EXITCODE
env:
CL_DATABASE_URL: ${{ env.DB_URL }}