Skip to content

Commit 2f0c8e9

Browse files
authored
[DX-3553] add CRE upgrade job to nightly and release (#21666)
* add CRE upgrade pipeline * bump CTF * pass some buildcmd * save Docker logs * clean up + uncomment df1 compat tests * exclude rc and beta refs from upgrade tests * support passing custom refs * add upgrade tests to build publish pipeline
1 parent 4cfccea commit 2f0c8e9

9 files changed

Lines changed: 100 additions & 11 deletions

File tree

.github/workflows/build-publish.yml

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,45 @@ jobs:
205205
products: |
206206
ccip-prereleases-prod-testnet
207207
208+
# Upgrade compatibility tests
209+
df1-compat:
210+
uses: ./.github/workflows/devenv-compat.yml
211+
name: Data Feeds v1 Upgrade Test
212+
needs: [docker-core]
213+
with:
214+
buildcmd: "just cli"
215+
envcmd: "cl u env.toml,products/ocr2/basic.toml"
216+
testcmd: "cl test ocr2 TestSmoke/rounds"
217+
upgrade-nodes: "3"
218+
node-name-template: "don-node%d"
219+
versions-back: "2"
220+
# uncomment once we have tested this pipeline with beta/rc releases
221+
# exclude-refs: "beta,rc"
222+
working-directory: "devenv"
223+
logs-directory: "./devenv/tests/ocr2/logs"
224+
ctf-log-level: "info"
225+
strip-image-suffix: "v"
226+
secrets: inherit
227+
228+
cre-compat:
229+
uses: ./.github/workflows/devenv-compat.yml
230+
name: CRE Upgrade Test
231+
needs: [docker-core]
232+
with:
233+
buildcmd: "echo nothing-to-build" # added to prevent `just cli` from being used (default buildcmd if not provided)
234+
envcmd: "go run -C ../../core/scripts/cre/environment . env start"
235+
testcmd: "go test -v -run Test_Upgrade_Suite ./smoke/cre"
236+
upgrade-nodes: "3"
237+
node-name-template: "workflow-node%d"
238+
versions-back: "2"
239+
# uncomment once we have tested this pipeline with beta/rc releases
240+
# exclude-refs: "beta,rc"
241+
working-directory: "./system-tests/tests"
242+
logs-directory: "./system-tests/tests/smoke/cre/logs"
243+
ctf-log-level: "info"
244+
strip-image-suffix: "v"
245+
secrets: inherit
246+
208247
# Notify Slack channel for new git tags associated with pre-releases.
209248
# Final release notifications originate from the release coordinator repo.
210249
slack-notify:

.github/workflows/devenv-compat.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,10 @@ on:
2020
description: "Git refs to test, should be used only for tool testing purposes. In all other cases refs are detected automatically either from Git or RANE SOT"
2121
required: false
2222
type: string
23+
exclude-refs:
24+
description: "Patterns to exclude specific refs (e.g., beta,rc,v0,v1)"
25+
required: false
26+
type: string
2327
buildcmd:
2428
description: "Build command to run"
2529
required: true
@@ -83,6 +87,7 @@ jobs:
8387
PRODUCT: ${{ inputs.product }}
8488
NO_GIT_ROLLBACK: ${{ inputs.no-git-rollback && '--no-git-rollback' || '' }} # Convert boolean to flag string
8589
REFS: ${{ inputs.refs }}
90+
EXCLUDE_REFS: ${{ inputs.exclude-refs }}
8691
BUILD_CMD: ${{ inputs.buildcmd }}
8792
ENV_CMD: ${{ inputs.envcmd }}
8893
TEST_CMD: ${{ inputs.testcmd }}
@@ -175,13 +180,18 @@ jobs:
175180
if [ -n "${{ env.REFS }}" ]; then
176181
REFS_ARGS="--refs ${{ env.REFS }}"
177182
fi
183+
EXCLUDE_REFS_ARGS=""
184+
if [ -n "${{ env.EXCLUDE_REFS }}" ]; then
185+
EXCLUDE_REFS_ARGS="--exclude-refs ${{ env.EXCLUDE_REFS }}"
186+
fi
178187
./bin/ctf compat backward \
179188
--registry "${REGISTRY}" \
180189
--buildcmd "${BUILD_CMD}" \
181190
--envcmd "${ENV_CMD}" \
182191
--testcmd "${TEST_CMD}" \
183192
--product "${PRODUCT}" \
184193
${REFS_ARGS} \
194+
${EXCLUDE_REFS_ARGS} \
185195
--upgrade-nodes "${UPGRADE_NODES}" \
186196
--don_nodes "${DON_NODES}" \
187197
--node-name-template "${NODE_NAME_TEMPLATE}" \

.github/workflows/devenv-nightly-compat.yml

Lines changed: 42 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,11 @@ on:
44
schedule:
55
- cron: "0 6 * * *" # Run daily at 6 AM
66
workflow_dispatch:
7+
inputs:
8+
refs:
9+
description: "Git refs to test, should be used only if automatically detected refs are not enough"
10+
required: false
11+
type: string
712

813
permissions:
914
id-token: write
@@ -14,7 +19,7 @@ jobs:
1419
# CREcluster compatibility and upgrade test
1520
# TODO
1621

17-
# Data Feeds v1 upgrade test
22+
# Data Feeds v1 upgrade test
1823
# this verifies that all the versions existing in RANE SOT for Data Feeds v1 can be upgraded to the latest version
1924
# TODO: disabled for now until we have connectivity
2025
# df1-upgrade:
@@ -40,6 +45,7 @@ jobs:
4045
# use it as an example project
4146
df1-compat:
4247
uses: ./.github/workflows/devenv-compat.yml
48+
name: Data Feeds v1 Upgrade Test
4349
with:
4450
# bash command to build your environment, omit if you are using 'devenv'
4551
buildcmd: "just cli"
@@ -49,10 +55,14 @@ jobs:
4955
testcmd: "cl test ocr2 TestSmoke/rounds"
5056
# number of CL nodes to upgrade with new version
5157
upgrade-nodes: "3"
52-
# cl node Docker cocntainer name template, omit if you are using 'devenv'
58+
# cl node Docker container name template, omit if you are using 'devenv'
5359
node-name-template: "don-node%d"
5460
# previous versions to test (sorted by tags, SemVer)
5561
versions-back: "2"
62+
# patterns to exclude specific refs
63+
exclude-refs: "beta,rc"
64+
# Git refs to test, should be used only for tool testing purposes.
65+
refs: ${{ github.event_name == 'workflow_dispatch' && inputs.refs || '' }}
5666
# directory with your developer environment to run buildcmd and envcmd
5767
working-directory: "devenv"
5868
# directory for executing your tests, to run testcmd
@@ -62,3 +72,33 @@ jobs:
6272
# this is needed to remove 'v' from Git tags to match SDLC ECR tags
6373
strip-image-suffix: "v"
6474
secrets: inherit
75+
76+
cre-compat:
77+
uses: ./.github/workflows/devenv-compat.yml
78+
name: CRE Upgrade Test
79+
with:
80+
# bash command to build your environment, omit if you are using 'devenv'
81+
buildcmd: "echo nothing-to-build"
82+
# bash command to spin up your environment and product orchestration
83+
envcmd: "go run -C ../../core/scripts/cre/environment . env start"
84+
# bash command to run the test verifying your product
85+
testcmd: "go test -v -run Test_Upgrade_Suite ./smoke/cre"
86+
# number of CL nodes to upgrade with new version
87+
upgrade-nodes: "3"
88+
# cl node Docker container name template, omit if you are using 'devenv'
89+
node-name-template: "workflow-node%d"
90+
# previous versions to test (sorted by tags, SemVer)
91+
versions-back: "2"
92+
# patterns to exclude specific refs
93+
exclude-refs: "beta,rc"
94+
# Git refs to test, should be used only for tool testing purposes.
95+
refs: ${{ github.event_name == 'workflow_dispatch' && inputs.refs || '' }}
96+
# directory with your developer environment to run buildcmd and envcmd
97+
working-directory: "./system-tests/tests"
98+
# directory for executing your tests, to run testcmd
99+
logs-directory: "./system-tests/tests/smoke/cre/logs"
100+
# CTF log level
101+
ctf-log-level: "info"
102+
# this is needed to remove 'v' from Git tags to match SDLC ECR tags
103+
strip-image-suffix: "v"
104+
secrets: inherit

core/scripts/go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ require (
5454
github.com/smartcontractkit/chainlink-evm/gethwrappers v0.0.0-20260119171452-39c98c3b33cd
5555
github.com/smartcontractkit/chainlink-protos/cre/go v0.0.0-20260320153346-314ec8dbe5a4
5656
github.com/smartcontractkit/chainlink-protos/job-distributor v0.18.0
57-
github.com/smartcontractkit/chainlink-testing-framework/framework v0.15.5
57+
github.com/smartcontractkit/chainlink-testing-framework/framework v0.15.8
5858
github.com/smartcontractkit/chainlink-testing-framework/framework/components/dockercompose v0.1.20
5959
github.com/smartcontractkit/chainlink-testing-framework/lib v1.54.5
6060
github.com/smartcontractkit/chainlink-testing-framework/seth v1.51.5

core/scripts/go.sum

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

system-tests/lib/go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ require (
4141
github.com/smartcontractkit/chainlink-protos/job-distributor v0.18.0
4242
github.com/smartcontractkit/chainlink-protos/workflows/go v0.0.0-20260217043601-5cc966896c4f
4343
github.com/smartcontractkit/chainlink-solana v1.1.2-0.20260325152920-167c7a34804c
44-
github.com/smartcontractkit/chainlink-testing-framework/framework v0.15.5
44+
github.com/smartcontractkit/chainlink-testing-framework/framework v0.15.8
4545
github.com/smartcontractkit/chainlink-testing-framework/framework/components/dockercompose v0.1.15
4646
github.com/smartcontractkit/chainlink-testing-framework/framework/components/fake v0.10.0
4747
github.com/smartcontractkit/chainlink-testing-framework/lib v1.54.5

system-tests/lib/go.sum

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

system-tests/tests/go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ require (
6666
github.com/smartcontractkit/chainlink-protos/job-distributor v0.18.0
6767
github.com/smartcontractkit/chainlink-protos/ring/go v0.0.0-20260128151123-605e9540b706
6868
github.com/smartcontractkit/chainlink-protos/workflows/go v0.0.0-20260217043601-5cc966896c4f
69-
github.com/smartcontractkit/chainlink-testing-framework/framework v0.15.5
69+
github.com/smartcontractkit/chainlink-testing-framework/framework v0.15.8
7070
github.com/smartcontractkit/chainlink-testing-framework/framework/components/fake v0.10.0
7171
github.com/smartcontractkit/chainlink-testing-framework/havoc v1.50.7
7272
github.com/smartcontractkit/chainlink-testing-framework/lib v1.54.5

system-tests/tests/go.sum

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)