Skip to content

Commit f340e07

Browse files
ordianlexnv
andauthored
migrate zombie past slashing test (paritytech#7147)
to zombienet-sdk 0.2.24 (also needed to update to this version for slashing to work). --------- Signed-off-by: Alexandru Vasile <[email protected]> Co-authored-by: Alexandru Vasile <[email protected]>
1 parent 42a6167 commit f340e07

File tree

9 files changed

+338
-140
lines changed

9 files changed

+338
-140
lines changed

.gitlab/pipeline/zombienet/polkadot.yml

+27-19
Original file line numberDiff line numberDiff line change
@@ -112,14 +112,6 @@ zombienet-polkadot-functional-0004-parachains-disputes-garbage-candidate:
112112
--local-dir="${LOCAL_DIR}/functional"
113113
--test="0004-parachains-garbage-candidate.zndsl"
114114

115-
.zombienet-polkadot-functional-0005-parachains-disputes-past-session:
116-
extends:
117-
- .zombienet-polkadot-common
118-
script:
119-
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
120-
--local-dir="${LOCAL_DIR}/functional"
121-
--test="0005-parachains-disputes-past-session.zndsl"
122-
123115
zombienet-polkadot-functional-0006-parachains-max-tranche0:
124116
extends:
125117
- .zombienet-polkadot-common
@@ -188,7 +180,7 @@ zombienet-polkadot-functional-0015-coretime-shared-core:
188180
extends:
189181
- .zombienet-polkadot-common
190182
before_script:
191-
- !reference [ .zombienet-polkadot-common, before_script ]
183+
- !reference [.zombienet-polkadot-common, before_script]
192184
- cp --remove-destination ${LOCAL_DIR}/assign-core.js ${LOCAL_DIR}/functional
193185
script:
194186
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
@@ -207,7 +199,7 @@ zombienet-polkadot-functional-0018-shared-core-idle-parachain:
207199
extends:
208200
- .zombienet-polkadot-common
209201
before_script:
210-
- !reference [ .zombienet-polkadot-common, before_script ]
202+
- !reference [.zombienet-polkadot-common, before_script]
211203
- cp --remove-destination ${LOCAL_DIR}/assign-core.js ${LOCAL_DIR}/functional
212204
script:
213205
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
@@ -218,7 +210,7 @@ zombienet-polkadot-functional-0019-coretime-collation-fetching-fairness:
218210
extends:
219211
- .zombienet-polkadot-common
220212
before_script:
221-
- !reference [ .zombienet-polkadot-common, before_script ]
213+
- !reference [.zombienet-polkadot-common, before_script]
222214
- cp --remove-destination ${LOCAL_DIR}/assign-core.js ${LOCAL_DIR}/functional
223215
script:
224216
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
@@ -354,7 +346,7 @@ zombienet-polkadot-malus-0001-dispute-valid:
354346
- job: build-polkadot-zombienet-tests
355347
artifacts: true
356348
before_script:
357-
- !reference [ ".zombienet-polkadot-common", "before_script" ]
349+
- !reference [".zombienet-polkadot-common", "before_script"]
358350
- export POLKADOT_IMAGE="${ZOMBIENET_INTEGRATION_TEST_IMAGE}"
359351
script:
360352
# we want to use `--no-capture` in zombienet tests.
@@ -369,7 +361,7 @@ zombienet-polkadot-elastic-scaling-slot-based-3cores:
369361
- job: build-polkadot-zombienet-tests
370362
artifacts: true
371363
before_script:
372-
- !reference [ ".zombienet-polkadot-common", "before_script" ]
364+
- !reference [".zombienet-polkadot-common", "before_script"]
373365
- export POLKADOT_IMAGE="${ZOMBIENET_INTEGRATION_TEST_IMAGE}"
374366
- export CUMULUS_IMAGE="docker.io/paritypr/test-parachain:${PIPELINE_IMAGE_TAG}"
375367
- export X_INFRA_INSTANCE=spot # use spot by default
@@ -386,7 +378,7 @@ zombienet-polkadot-elastic-scaling-slot-based-12cores:
386378
- job: build-polkadot-zombienet-tests
387379
artifacts: true
388380
before_script:
389-
- !reference [ ".zombienet-polkadot-common", "before_script" ]
381+
- !reference [".zombienet-polkadot-common", "before_script"]
390382
- export POLKADOT_IMAGE="${ZOMBIENET_INTEGRATION_TEST_IMAGE}"
391383
- export CUMULUS_IMAGE="docker.io/paritypr/test-parachain:${PIPELINE_IMAGE_TAG}"
392384
- export X_INFRA_INSTANCE=spot # use spot by default
@@ -403,7 +395,7 @@ zombienet-polkadot-elastic-scaling-doesnt-break-parachains:
403395
- job: build-polkadot-zombienet-tests
404396
artifacts: true
405397
before_script:
406-
- !reference [ ".zombienet-polkadot-common", "before_script" ]
398+
- !reference [".zombienet-polkadot-common", "before_script"]
407399
- export POLKADOT_IMAGE="${ZOMBIENET_INTEGRATION_TEST_IMAGE}"
408400
- export X_INFRA_INSTANCE=spot # use spot by default
409401
variables:
@@ -421,7 +413,7 @@ zombienet-polkadot-elastic-scaling-basic-3cores:
421413
- job: build-polkadot-zombienet-tests
422414
artifacts: true
423415
before_script:
424-
- !reference [ ".zombienet-polkadot-common", "before_script" ]
416+
- !reference [".zombienet-polkadot-common", "before_script"]
425417
- export POLKADOT_IMAGE="${ZOMBIENET_INTEGRATION_TEST_IMAGE}"
426418
- export CUMULUS_IMAGE="${COL_IMAGE}"
427419
- export X_INFRA_INSTANCE=spot # use spot by default
@@ -438,7 +430,7 @@ zombienet-polkadot-functional-sync-backing:
438430
- job: build-polkadot-zombienet-tests
439431
artifacts: true
440432
before_script:
441-
- !reference [ ".zombienet-polkadot-common", "before_script" ]
433+
- !reference [".zombienet-polkadot-common", "before_script"]
442434
- export POLKADOT_IMAGE="${ZOMBIENET_INTEGRATION_TEST_IMAGE}"
443435
# Hardcoded to an old polkadot-parachain image, pre async backing.
444436
- export CUMULUS_IMAGE="docker.io/paritypr/polkadot-parachain-debug:master-99623e62"
@@ -456,7 +448,7 @@ zombienet-polkadot-functional-async-backing-6-seconds-rate:
456448
- job: build-polkadot-zombienet-tests
457449
artifacts: true
458450
before_script:
459-
- !reference [ ".zombienet-polkadot-common", "before_script" ]
451+
- !reference [".zombienet-polkadot-common", "before_script"]
460452
- export POLKADOT_IMAGE="${ZOMBIENET_INTEGRATION_TEST_IMAGE}"
461453
- export X_INFRA_INSTANCE=spot # use spot by default
462454
script:
@@ -472,11 +464,27 @@ zombienet-polkadot-functional-duplicate-collations:
472464
- job: build-polkadot-zombienet-tests
473465
artifacts: true
474466
before_script:
475-
- !reference [ ".zombienet-polkadot-common", "before_script" ]
467+
- !reference [".zombienet-polkadot-common", "before_script"]
476468
- export POLKADOT_IMAGE="${ZOMBIENET_INTEGRATION_TEST_IMAGE}"
477469
- export X_INFRA_INSTANCE=spot # use spot by default
478470
script:
479471
# we want to use `--no-capture` in zombienet tests.
480472
- unset NEXTEST_FAILURE_OUTPUT
481473
- unset NEXTEST_SUCCESS_OUTPUT
482474
- cargo nextest run --archive-file ./artifacts/polkadot-zombienet-tests.tar.zst --no-capture -- functional::duplicate_collations::duplicate_collations_test
475+
476+
zombienet-polkadot-disputes-slashing:
477+
extends:
478+
- .zombienet-polkadot-common
479+
needs:
480+
- job: build-polkadot-zombienet-tests
481+
artifacts: true
482+
before_script:
483+
- !reference [".zombienet-polkadot-common", "before_script"]
484+
- export POLKADOT_IMAGE="${ZOMBIENET_INTEGRATION_TEST_IMAGE}"
485+
- export X_INFRA_INSTANCE=spot # use spot by default
486+
script:
487+
# we want to use `--no-capture` in zombienet tests.
488+
- unset NEXTEST_FAILURE_OUTPUT
489+
- unset NEXTEST_SUCCESS_OUTPUT
490+
- cargo nextest run --archive-file ./artifacts/polkadot-zombienet-tests.tar.zst --no-capture -- disabling::slashing

Cargo.lock

+110-17
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

polkadot/zombienet-sdk-tests/Cargo.toml

+1
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ serde_json = { workspace = true }
1818
subxt = { workspace = true, features = ["substrate-compat"] }
1919
subxt-signer = { workspace = true }
2020
tokio = { workspace = true, features = ["rt-multi-thread"] }
21+
tokio-util = { workspace = true, features = ["time"] }
2122
zombienet-sdk = { workspace = true }
2223

2324
[features]
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
// Copyright (C) Parity Technologies (UK) Ltd.
2+
// SPDX-License-Identifier: Apache-2.0
3+
4+
mod slashing;

0 commit comments

Comments
 (0)