1111 - ready_for_review
1212 paths-ignore :
1313 - docs/**
14- - ' **.md'
14+ - " **.md"
1515 - .github/**
1616 - .gitignore
1717 push :
1818 branches :
1919 - main
2020 paths-ignore :
2121 - docs/**
22- - ' **.md'
22+ - " **.md"
2323 - .github/**
2424# run concurrency group for the workflow
2525concurrency :
@@ -38,14 +38,14 @@ jobs:
3838 steps :
3939 # Checkout the repository
4040 - name : Harden the runner (Audit all outbound calls)
41- uses : step-security/harden-runner@df199fb7be9f65074067a9eb93f12bb4c5547cf2 # v2.13.3
41+ uses : step-security/harden-runner@df199fb7be9f65074067a9eb93f12bb4c5547cf2 # v2.13.3
4242 with :
4343 egress-policy : audit
4444 - name : Checkout Code
45- uses : actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
45+ uses : actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
4646 - name : Get changed files
4747 id : changed-files-yaml
48- uses : tj-actions/changed-files@24d32ffd492484c1d75e0c0b894501ddb9d30d62 # v47.0.0
48+ uses : tj-actions/changed-files@24d32ffd492484c1d75e0c0b894501ddb9d30d62 # v47.0.0
4949 with :
5050 files_yaml : |
5151 code:
6565 - '**/*.rs'
6666 - tests/**/*.json
6767 ci :
68+ timeout-minutes : 150
6869 if : ${{ github.event.pull_request.draft == false && always() }}
6970 permissions :
7071 contents : none
@@ -73,10 +74,10 @@ jobs:
7374 - msrv
7475 - rustfmt
7576 - clippy
76- runs-on : ubuntu-latest
77+ runs-on : ubuntu-22.04-oz-8core
7778 steps :
7879 - name : Harden the runner (Audit all outbound calls)
79- uses : step-security/harden-runner@df199fb7be9f65074067a9eb93f12bb4c5547cf2 # v2.13.3
80+ uses : step-security/harden-runner@df199fb7be9f65074067a9eb93f12bb4c5547cf2 # v2.13.3
8081 with :
8182 egress-policy : audit
8283 - name : Failed
@@ -89,11 +90,11 @@ jobs:
8990 steps :
9091 # Checkout the repository
9192 - name : Harden the runner (Audit all outbound calls)
92- uses : step-security/harden-runner@df199fb7be9f65074067a9eb93f12bb4c5547cf2 # v2.13.3
93+ uses : step-security/harden-runner@df199fb7be9f65074067a9eb93f12bb4c5547cf2 # v2.13.3
9394 with :
9495 egress-policy : audit
9596 - name : Checkout Code
96- uses : actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
97+ uses : actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
9798 - name : Prepare
9899 id : init
99100 uses : ./.github/actions/prepare
@@ -102,7 +103,7 @@ jobs:
102103 - name : Get cache-hit output
103104 run : ' echo "Cache hit >>>>>: ${{ steps.init.outputs.cache-hit }}"'
104105 - name : Install cargo hack
105- uses : taiki-e/install-action@92e6dd1c202153a204d471a3c509bf1e03dcfa44 # v2.62.61
106+ uses : taiki-e/install-action@92e6dd1c202153a204d471a3c509bf1e03dcfa44 # v2.62.61
106107 with :
107108 tool : cargo-hack
108109
@@ -116,11 +117,11 @@ jobs:
116117 steps :
117118 # Checkout the repository
118119 - name : Harden the runner (Audit all outbound calls)
119- uses : step-security/harden-runner@df199fb7be9f65074067a9eb93f12bb4c5547cf2 # v2.13.3
120+ uses : step-security/harden-runner@df199fb7be9f65074067a9eb93f12bb4c5547cf2 # v2.13.3
120121 with :
121122 egress-policy : audit
122123 - name : Checkout Code
123- uses : actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
124+ uses : actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
124125 - name : Prepare
125126 id : init
126127 uses : ./.github/actions/prepare
@@ -139,11 +140,11 @@ jobs:
139140 steps :
140141 # Checkout the repository
141142 - name : Harden the runner (Audit all outbound calls)
142- uses : step-security/harden-runner@df199fb7be9f65074067a9eb93f12bb4c5547cf2 # v2.13.3
143+ uses : step-security/harden-runner@df199fb7be9f65074067a9eb93f12bb4c5547cf2 # v2.13.3
143144 with :
144145 egress-policy : audit
145146 - name : Checkout Code
146- uses : actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
147+ uses : actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
147148 - name : Prepare
148149 id : init
149150 uses : ./.github/actions/prepare
@@ -163,13 +164,13 @@ jobs:
163164 | sarif-fmt
164165 continue-on-error : true
165166 - name : upload sarif artifact
166- uses : actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0
167+ uses : actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0
167168 with :
168169 name : clippy-results.sarif
169170 path : clippy-results.sarif
170171 retention-days : 1
171172 - name : Upload
172- uses : github/codeql-action/upload-sarif@fe4161a26a8629af62121b670040955b330f9af2 # v3.29.5
173+ uses : github/codeql-action/upload-sarif@fe4161a26a8629af62121b670040955b330f9af2 # v3.29.5
173174 with :
174175 sarif_file : clippy-results.sarif
175176 wait-for-processing : true
@@ -181,19 +182,19 @@ jobs:
181182 contents : read
182183 needs :
183184 - changed_files
184- runs-on : ubuntu-latest
185+ runs-on : ubuntu-22.04-oz-8core
185186 steps :
186187 # Checkout the repository
187188 - name : Harden the runner (Audit all outbound calls)
188- uses : step-security/harden-runner@df199fb7be9f65074067a9eb93f12bb4c5547cf2 # v2.13.3
189+ uses : step-security/harden-runner@df199fb7be9f65074067a9eb93f12bb4c5547cf2 # v2.13.3
189190 with :
190191 egress-policy : audit
191192 - name : Checkout Code
192- uses : actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
193+ uses : actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
193194 - name : Setup Node.js
194- uses : actions/setup-node@395ad3262231945c25e8478fd5baf05154b1d79f # v6.1.0
195+ uses : actions/setup-node@395ad3262231945c25e8478fd5baf05154b1d79f # v6.1.0
195196 with :
196- node-version : ' 20 '
197+ node-version : " 20 "
197198 - name : Install pnpm and plugin dependencies
198199 run : |
199200 npm install -g pnpm
@@ -226,7 +227,7 @@ jobs:
226227 - name : Get cache-hit output
227228 run : ' echo "Cache hit >>>>>: ${{ steps.init.outputs.cache-hit }}"'
228229 - name : Install cargo hack and cargo-llvm-cov
229- uses : taiki-e/install-action@92e6dd1c202153a204d471a3c509bf1e03dcfa44 # v2.62.61
230+ uses : taiki-e/install-action@92e6dd1c202153a204d471a3c509bf1e03dcfa44 # v2.62.61
230231 with :
231232 tool : cargo-hack,cargo-llvm-cov
232233 - name : Build
@@ -255,9 +256,29 @@ jobs:
255256 RUST_TEST_THREADS : 1
256257 run : cargo hack llvm-cov --locked --ignore-filename-regex "(src/api/routes/docs/.*_docs\.rs$|src/repositories/.*/.*_redis\.rs$)" --lcov --output-path properties-lcov.info --test properties
257258
259+ - name : Run Developer Tests (excluding AI) and Generate Coverage Report
260+ id : dev_coverage
261+ timeout-minutes : 45
262+ env :
263+ LLVM_PROFILE_FILE : dev-%p-%m.profraw
264+ RUSTFLAGS : -Cinstrument-coverage
265+ RUST_TEST_THREADS : 1
266+ run : |
267+ cargo hack llvm-cov --locked --lib --ignore-filename-regex "(src/api/routes/docs/.*_docs\.rs$|src/repositories/.*/.*_redis\.rs$)" --lcov --output-path dev-lcov.info --tests -- --skip ai_
268+
269+ - name : Run AI Tests and Generate Coverage Report
270+ id : ai_coverage
271+ timeout-minutes : 45
272+ env :
273+ LLVM_PROFILE_FILE : ai-%p-%m.profraw
274+ RUSTFLAGS : -Cinstrument-coverage
275+ RUST_TEST_THREADS : 1
276+ run : |
277+ cargo hack llvm-cov --locked --lib --ignore-filename-regex "(src/api/routes/docs/.*_docs\.rs$|src/repositories/.*/.*_redis\.rs$)" --lcov --output-path ai-lcov.info --tests -- ai_
278+
258279 # Upload unit coverage
259280 - name : Upload Unit Coverage to Codecov
260- uses : codecov/codecov-action@5a1091511ad55cbe89839c7260b706298ca349f7 # v5.5.1
281+ uses : codecov/codecov-action@5a1091511ad55cbe89839c7260b706298ca349f7 # v5.5.1
261282 with :
262283 token : ${{ secrets.CODECOV_TOKEN }}
263284 name : unit-coverage
@@ -267,7 +288,7 @@ jobs:
267288
268289 # Upload integration coverage
269290 - name : Upload Integration Coverage to Codecov
270- uses : codecov/codecov-action@5a1091511ad55cbe89839c7260b706298ca349f7 # v5.5.1
291+ uses : codecov/codecov-action@5a1091511ad55cbe89839c7260b706298ca349f7 # v5.5.1
271292 with :
272293 token : ${{ secrets.CODECOV_TOKEN }}
273294 name : integration-coverage
@@ -277,13 +298,32 @@ jobs:
277298
278299 # Upload properties coverage
279300 - name : Upload Properties Coverage to Codecov
280- uses : codecov/codecov-action@5a1091511ad55cbe89839c7260b706298ca349f7 # v5.5.1
301+ uses : codecov/codecov-action@5a1091511ad55cbe89839c7260b706298ca349f7 # v5.5.1
281302 with :
282303 token : ${{ secrets.CODECOV_TOKEN }}
283304 name : properties-coverage
284305 files : properties-lcov.info
285306 flags : properties
286307 fail_ci_if_error : true
308+
309+ - name : Upload AI Coverage to Codecov
310+ uses : codecov/codecov-action@5a1091511ad55cbe89839c7260b706298ca349f7 # v5.5.1
311+ with :
312+ token : ${{ secrets.CODECOV_TOKEN }}
313+ name : ai-coverage
314+ files : ai-lcov.info
315+ flags : ai
316+ fail_ci_if_error : true
317+
318+ - name : Upload Developer Coverage to Codecov
319+ uses : codecov/codecov-action@5a1091511ad55cbe89839c7260b706298ca349f7 # v5.5.1
320+ with :
321+ token : ${{ secrets.CODECOV_TOKEN }}
322+ name : dev-coverage
323+ files : dev-lcov.info
324+ flags : dev
325+ fail_ci_if_error : true
326+
287327 docker-scan :
288328 runs-on : ubuntu-latest
289329 needs :
@@ -294,23 +334,23 @@ jobs:
294334 steps :
295335 # Checkout the repository
296336 - name : Harden the runner (Audit all outbound calls)
297- uses : step-security/harden-runner@df199fb7be9f65074067a9eb93f12bb4c5547cf2 # v2.13.3
337+ uses : step-security/harden-runner@df199fb7be9f65074067a9eb93f12bb4c5547cf2 # v2.13.3
298338 with :
299339 egress-policy : audit
300340 - name : Checkout Code
301- uses : actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
341+ uses : actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
302342 - name : Set up Docker Buildx
303- uses : docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435 # v3.11.1
343+ uses : docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435 # v3.11.1
304344 - name : Build local container
305- uses : docker/build-push-action@263435318d21b8e681c14492fe198d362a7d2c83 # v6.18.0
345+ uses : docker/build-push-action@263435318d21b8e681c14492fe198d362a7d2c83 # v6.18.0
306346 with :
307347 tags : openzeppelin-relayer-dev:${{ github.sha }}
308348 push : false
309349 load : true
310350 file : Dockerfile.development
311351 platforms : linux/amd64
312352 - name : Scan image
313- uses : anchore/scan-action@40a61b52209e9d50e87917c5b901783d546b12d0 # v7.2.1
353+ uses : anchore/scan-action@40a61b52209e9d50e87917c5b901783d546b12d0 # v7.2.1
314354 with :
315355 image : openzeppelin-relayer-dev:${{ github.sha }}
316356 fail-build : true
0 commit comments