Skip to content

Commit 88a10be

Browse files
committed
feat: split nightly replays and nightly
1 parent 92e192c commit 88a10be

File tree

10 files changed

+66
-43
lines changed

10 files changed

+66
-43
lines changed

.github/workflows/gradle-nightly-tests.yml

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -18,36 +18,31 @@ jobs:
1818
with:
1919
zkevm_fork: LONDON
2020
tests-with-ssh: ${{ inputs.tests-with-ssh || false }}
21-
with-replays: true
2221

2322
nightly-tests-paris:
2423
uses: ./.github/workflows/reusable-nightly-tests.yml
2524
secrets: inherit
2625
with:
2726
zkevm_fork: PARIS
2827
tests-with-ssh: ${{ inputs.tests-with-ssh || false }}
29-
with-replays: false
3028

3129
nightly-tests-shanghai:
3230
uses: ./.github/workflows/reusable-nightly-tests.yml
3331
secrets: inherit
3432
with:
3533
zkevm_fork: SHANGHAI
3634
tests-with-ssh: ${{ inputs.tests-with-ssh || false }}
37-
with-replays: false
3835

3936
nightly-tests-cancun:
4037
uses: ./.github/workflows/reusable-nightly-tests.yml
4138
secrets: inherit
4239
with:
4340
zkevm_fork: CANCUN
4441
tests-with-ssh: ${{ inputs.tests-with-ssh || false }}
45-
with-replays: false
4642

4743
nightly-tests-prague:
4844
uses: ./.github/workflows/reusable-nightly-tests.yml
4945
secrets: inherit
5046
with:
5147
zkevm_fork: PRAGUE
5248
tests-with-ssh: ${{ inputs.tests-with-ssh || false }}
53-
with-replays: false
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
name: Nightly Replay Tests
2+
permissions:
3+
contents: read
4+
5+
on:
6+
schedule:
7+
- cron: "0 22 * * 1-5"
8+
workflow_dispatch:
9+
10+
concurrency:
11+
group: ${{ github.workflow }}-${{ github.ref }}
12+
cancel-in-progress: true
13+
14+
jobs:
15+
# ==================================================================
16+
# Replay Tests
17+
# ==================================================================
18+
nightly-replay-tests:
19+
runs-on: gha-runner-scale-set-ubuntu-22.04-amd64-xxl
20+
steps:
21+
- name: Checkout repository
22+
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
23+
with:
24+
submodules: recursive
25+
26+
- name: Setup Test Environment
27+
uses: ./.github/actions/setup-environment
28+
29+
- name: Run Nightly Replay tests
30+
run: GOMAXPROCS=10 GOMEMLIMIT=20GiB ./gradlew nightlyReplayTests
31+
env:
32+
JAVA_OPTS: -Dorg.gradle.daemon=false
33+
GOCORSET_FLAGS: -v --ansi-escapes=false --report --mir
34+
NIGHTLY_REPLAY_TESTS_PARALLELISM: 2
35+
36+
- name: Upload test report
37+
if: ${{ always() }}
38+
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
39+
with:
40+
name: nightly-replay-tests-report-${{ inputs.zkevm_fork }}
41+
path: arithmetization/build/reports/tests/**/*
42+
43+
- name: Failure Notification
44+
if: github.ref == 'refs/heads/arith-dev' && (failure() || cancelled())
45+
uses: slackapi/slack-github-action@91efab103c0de0a537f72a35f6b8cda0ee76bf0a # v2.1.1
46+
with:
47+
webhook: ${{ secrets.SLACK_WEBHOOK_URL }}
48+
webhook-type: webhook-trigger
49+
payload: |
50+
name: "NightlyReplay"
51+
status: "${{ job.status }}"

.github/workflows/reusable-nightly-tests.yml

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,6 @@ on:
66
zkevm_fork:
77
required: true
88
type: string
9-
with-replays:
10-
required: true
11-
type: boolean
129
tests-with-ssh:
1310
required: true
1411
type: boolean
@@ -30,16 +27,6 @@ jobs:
3027

3128
- name: Run Nightly tests
3229
run: GOMAXPROCS=10 GOMEMLIMIT=20GiB ./gradlew nightlyTests
33-
if : ${{ inputs.with-replays == true }}
34-
env:
35-
JAVA_OPTS: -Dorg.gradle.daemon=false
36-
GOCORSET_FLAGS: -v --ansi-escapes=false --report --mir
37-
NIGHTLY_TESTS_PARALLELISM: 2
38-
ZKEVM_FORK: ${{ inputs.zkevm_fork }}
39-
40-
- name: Run Nightly No Replay tests
41-
run: GOMAXPROCS=10 GOMEMLIMIT=20GiB ./gradlew nightlyNoReplayTests
42-
if : ${{ inputs.with-replays == false }}
4330
env:
4431
JAVA_OPTS: -Dorg.gradle.daemon=false
4532
GOCORSET_FLAGS: -v --ansi-escapes=false --report --mir

arithmetization/src/test/java/net/consensys/linea/replaytests/HubShomeiReplayTests.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
import org.junit.jupiter.api.TestInfo;
2626
import org.junit.jupiter.api.extension.ExtendWith;
2727

28-
@Tag("nightly")
28+
@Tag("replay")
2929
@ExtendWith(UnitTestWatcher.class)
3030
public class HubShomeiReplayTests extends TracerTestBase {
3131

arithmetization/src/test/java/net/consensys/linea/replaytests/Issue1123Tests.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@
2929
@ExtendWith(UnitTestWatcher.class)
3030
public class Issue1123Tests extends TracerTestBase {
3131

32-
@Tag("nightly")
3332
@Test
3433
void issue_1123_mainnet_block_8043758(TestInfo testInfo) {
3534
replay(OLD_MAINNET_TESTCONFIG, "8043758.mainnet.json.gz", testInfo);

arithmetization/src/test/java/net/consensys/linea/replaytests/Issue1136Tests.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,6 @@
4242
* <p><a href="https://github.com/Consensys/linea-tracer/issues/1153">Related GitHub issue</a>
4343
*/
4444
@Tag("replay")
45-
@Tag("nightly")
4645
@ExtendWith(UnitTestWatcher.class)
4746
public class Issue1136Tests extends TracerTestBase {
4847

arithmetization/src/test/java/net/consensys/linea/replaytests/Issue1216Tests.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,6 @@ public class Issue1216Tests extends TracerTestBase {
4646
* blowing up with a NPE since the "after" version of the self destructor didn't exist yet in the
4747
* code. This was solved in issue #1216.
4848
*/
49-
@Tag("nightly")
5049
@Tag("replay")
5150
@Test
5251
void issue_1216_sepolia_block_2392659(TestInfo testInfo) {

arithmetization/src/test/java/net/consensys/linea/replaytests/Issue1264Tests.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@
2424
import org.junit.jupiter.api.TestInfo;
2525
import org.junit.jupiter.api.extension.ExtendWith;
2626

27-
@Tag("nightly")
2827
@Tag("replay")
2928
@ExtendWith(UnitTestWatcher.class)
3029
public class Issue1264Tests extends TracerTestBase {

arithmetization/src/test/java/net/consensys/linea/replaytests/ReplayTests.java

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,6 @@ void multipleFailingCallToEcrecover(TestInfo testInfo) {
7676
}
7777

7878
@Test
79-
@Tag("nightly")
8079
void incident777zkGethMainnet(TestInfo testInfo) {
8180
replay(OLD_MAINNET_TESTCONFIG, "7461019-7461030.mainnet.json.gz", testInfo);
8281
}
@@ -163,7 +162,6 @@ void returnOogxForCodeDepositCost(TestInfo testInfo) {
163162
}
164163

165164
@Test
166-
@Tag("nightly")
167165
void modexpTriggeringNonAlignedFirstLimbSingleSourceMmuModexp(TestInfo testInfo) {
168166
replay(OLD_MAINNET_TESTCONFIG, "3108622-3108633.mainnet.json.gz", testInfo);
169167
}

gradle/tests.gradle

Lines changed: 14 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -215,6 +215,10 @@ tasks.register("downloadShoemiBesuPlugin", Download) {
215215
overwrite false
216216
}
217217

218+
/*
219+
* Nightly replay tests (only nightly replay) and Nightly tests (no replay)
220+
*/
221+
218222
tasks.register("fastReplayTests", Test) {
219223
if (System.getenv().containsKey("REPLAY_TESTS_PARALLELISM")) {
220224
systemProperty("junit.jupiter.execution.parallel.enabled", true)
@@ -278,43 +282,30 @@ tasks.register("jacocoFastReplayTestsReport", JacocoReport) {
278282
}
279283

280284
tasks.register("nightlyReplayTests", Test) {
281-
if (System.getenv().containsKey("REPLAY_TESTS_PARALLELISM")) {
285+
if (System.getenv().containsKey("NIGHTLY_REPLAY_TESTS_PARALLELISM")) {
282286
systemProperty("junit.jupiter.execution.parallel.enabled", true)
283287
systemProperty("junit.jupiter.execution.parallel.mode.default", "concurrent")
284288
systemProperty("junit.jupiter.execution.parallel.mode.classes.default", "concurrent")
285289
systemProperty("junit.jupiter.execution.parallel.config.strategy", "fixed")
286290
systemProperty("junit.jupiter.execution.parallel.config.fixed.parallelism",
287-
System.getenv().getOrDefault("REPLAY_TESTS_PARALLELISM", "1").toInteger())
291+
System.getenv().getOrDefault("NIGHTLY_REPLAY_TESTS_PARALLELISM", "1").toInteger())
288292
}
289293

290294
useJUnitPlatform {
291295
includeTags("replay")
292-
includeTags("nightly")
293-
}
294-
}
295-
296-
tasks.register("nightlyNoReplayTests", Test) {
297-
systemProperty("junit.jupiter.execution.parallel.enabled", true)
298-
systemProperty("junit.jupiter.execution.parallel.mode.default", "concurrent")
299-
systemProperty("junit.jupiter.execution.parallel.mode.classes.default", "concurrent")
300-
systemProperty("junit.jupiter.execution.parallel.config.strategy", "fixed")
301-
systemProperty("junit.jupiter.execution.parallel.config.fixed.parallelism",
302-
System.getenv().getOrDefault("NIGHTLY_TESTS_PARALLELISM", "1").toInteger())
303-
304-
useJUnitPlatform {
305-
includeTags("nightly")
306-
excludeTags("replay")
296+
excludeTags("weekly")
307297
}
308-
finalizedBy(jacocoNightlyTestsReport)
309298
}
310299

311300
tasks.register("nightlyTests", Test) {
301+
if (System.getenv().containsKey("NIGHTLY_REPLAY_TESTS_PARALLELISM")) {
312302
systemProperty("junit.jupiter.execution.parallel.enabled", true)
313303
systemProperty("junit.jupiter.execution.parallel.mode.default", "concurrent")
314304
systemProperty("junit.jupiter.execution.parallel.mode.classes.default", "concurrent")
315305
systemProperty("junit.jupiter.execution.parallel.config.strategy", "fixed")
316306
systemProperty("junit.jupiter.execution.parallel.config.fixed.parallelism",
317307
System.getenv().getOrDefault("NIGHTLY_TESTS_PARALLELISM", "1").toInteger())
308+
}
318309

319310
useJUnitPlatform {
320311
includeTags("nightly")
@@ -331,6 +322,11 @@ tasks.register("jacocoNightlyTestsReport", JacocoReport) {
331322
executionData(nightlyTests)
332323
}
333324

325+
/*
326+
* Weekly tests (include weekly replays and weekly tests)
327+
* Prc Calls tests (only prc calls tests)
328+
*/
329+
334330
tasks.register("weeklyTests", Test) {
335331
systemProperty("junit.jupiter.execution.parallel.enabled", true)
336332
systemProperty("junit.jupiter.execution.parallel.mode.default", "concurrent")

0 commit comments

Comments
 (0)