diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 8bb412728e53..f63688f8459b 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -623,6 +623,35 @@ zombienet-tests-parachains-smoke-test: tags: - zombienet-polkadot-integration-test +zombienet-regression-tests: + stage: stage3 + image: "${ZOMBIENET_IMAGE}" + <<: *kubernetes-env + <<: *zombienet-refs + needs: + - job: publish-polkadot-debug-image + - job: publish-test-collators-image + variables: + GH_DIR: "https://github.com/paritytech/polkadot/tree/${CI_COMMIT_SHORT_SHA}/zombienet_tests/regression" + before_script: + - echo "Zombie-net Tests Config" + - echo "${ZOMBIENET_IMAGE}" + - echo "${PARACHAINS_IMAGE_NAME} ${PARACHAINS_IMAGE_TAG}" + - echo "COL_IMAGE=${COLLATOR_IMAGE_NAME}:${COLLATOR_IMAGE_TAG}" + - echo "${GH_DIR}" + - export DEBUG=zombie,zombie::network-node + - export ZOMBIENET_INTEGRATION_TEST_IMAGE=${PARACHAINS_IMAGE_NAME}:${PARACHAINS_IMAGE_TAG} + - export MALUS_IMAGE=${MALUS_IMAGE_NAME}:${MALUS_IMAGE_TAG} + - export COL_IMAGE=${COLLATOR_IMAGE_NAME}:${COLLATOR_IMAGE_TAG} + script: + - /home/nonroot/zombie-net/scripts/ci/run-test-env-manager.sh + --github-remote-dir="${GH_DIR}" + --test="0003-small-net-no-paras.feature" + allow_failure: false + retry: 2 + tags: + - zombienet-polkadot-integration-test + zombienet-tests-parachains-pvf: stage: stage3 image: "${ZOMBIENET_IMAGE}" @@ -632,7 +661,7 @@ zombienet-tests-parachains-pvf: - job: publish-polkadot-debug-image - job: publish-test-collators-image variables: - GH_DIR: "https://github.com/paritytech/polkadot/tree/${CI_COMMIT_SHORT_SHA}/zombienet_tests/functional" + GH_DIR: "https://github.com/paritytech/polkadot/tree/${CI_COMMIT_SHORT_SHA}/zombienet_tests/regression" before_script: - echo "Zombie-net Tests Config" - echo "${ZOMBIENET_IMAGE}" @@ -805,5 +834,3 @@ cancel-pipeline: PROJECT_ID: "${CI_PROJECT_ID}" PIPELINE_ID: "${CI_PIPELINE_ID}" trigger: "parity/infrastructure/ci_cd/pipeline-stopper" - - diff --git a/zombienet_tests/regression/0003-small-net-no-paras.feature b/zombienet_tests/regression/0003-small-net-no-paras.feature new file mode 100644 index 000000000000..607f40ad9ee7 --- /dev/null +++ b/zombienet_tests/regression/0003-small-net-no-paras.feature @@ -0,0 +1,60 @@ +Description: Small net without paras does create relay chain blocks +Network: ./0003-small-net-no-paras.toml +Creds: config + +alice: is up +bob: is up +charlie: is up +dave: is up +eve: is up +ferdie: is up +one: is up +two: is up + +# Check authority status and peers. +alice: reports node_roles is 4 +bob: reports node_roles is 4 +charlie: reports node_roles is 4 +dave: reports node_roles is 4 +eve: reports node_roles is 4 +ferdie: reports node_roles is 4 +one: reports node_roles is 4 +two: reports node_roles is 4 + +alice: reports peers count is at least 7 within 20 seconds +bob: reports peers count is at least 7 within 20 seconds +charlie: reports peers count is at least 7 within 20 seconds +dave: reports peers count is at least 7 within 20 seconds +ferdie: reports peers count is at least 7 within 20 seconds +eve: reports peers count is at least 7 within 20 seconds +one: reports peers count is at least 7 within 20 seconds +two: reports peers count is at least 7 within 20 seconds + +alice: reports polkadot_parachain_approval_checking_finality_lag is 0 within 12 seconds +bob: reports polkadot_parachain_approval_checking_finality_lag is 0 within 12 seconds +charlie: reports polkadot_parachain_approval_checking_finality_lag is 0 within 12 seconds +dave: reports polkadot_parachain_approval_checking_finality_lag is 0 within 12 seconds +ferdie: reports polkadot_parachain_approval_checking_finality_lag is 0 within 12 seconds +eve: reports polkadot_parachain_approval_checking_finality_lag is 0 within 12 seconds +one: reports polkadot_parachain_approval_checking_finality_lag is 0 within 12 seconds +two: reports polkadot_parachain_approval_checking_finality_lag is 0 within 12 seconds + +# a session covers 3 blocks, so technically `6 seconds/block * 4 blocks` should be sufficient +# to produce 4 blocks, but we add a factor of 2, so 48 seconds +alice: reports block_height{status="best"} is at least 4 within 70 seconds +bob: reports block_height{status="best"} is at least 4 within 70 seconds +charlie: reports block_height{status="best"} is at least 4 within 70 seconds +dave: reports block_height{status="best"} is at least 4 within 70 seconds +ferdie: reports block_height{status="best"} is at least 4 within 70 seconds +eve: reports block_height{status="best"} is at least 4 within 70 seconds +one: reports block_height{status="best"} is at least 4 within 70 seconds +two: reports block_height{status="best"} is at least 4 within 70 seconds + +alice: reports block_height{status="finalized"} is at least 4 within 90 seconds +bob: reports block_height{status="finalized"} is at least 4 within 90 seconds +charlie: reports block_height{status="finalized"} is at least 4 within 90 seconds +dave: reports block_height{status="finalized"} is at least 4 within 90 seconds +ferdie: reports block_height{status="finalized"} is at least 4 within 90 seconds +eve: reports block_height{status="finalized"} is at least 4 within 90 seconds +one: reports block_height{status="finalized"} is at least 4 within 90 seconds +two: reports block_height{status="finalized"} is at least 4 within 90 seconds diff --git a/zombienet_tests/regression/0003-small-net-no-paras.toml b/zombienet_tests/regression/0003-small-net-no-paras.toml new file mode 100644 index 000000000000..d7e344a5077f --- /dev/null +++ b/zombienet_tests/regression/0003-small-net-no-paras.toml @@ -0,0 +1,31 @@ +[settings] +timeout = 1000 + + +# cannot be changed after the first block got produced +[relaychain.genesis.runtime] +session_length_in_block = 3 + +[relaychain] +default_image = "{{ZOMBIENET_INTEGRATION_TEST_IMAGE}}" +chain = "rococo-local" +chain_spec_command = "polkadot build-spec --chain rococo-local --disable-default-bootnode" +default_command = "polkadot" + +[relaychain.default_resources] +limits = { memory = "4G", cpu = "2" } +requests = { memory = "2G", cpu = "1" } + +[[relaychain.node_groups]] + name = "honest-validator" + count = 10 + args = ["-lparachain=debug,runtime=debug,afg=trace"] + + +# Zer0 parachains +#[[parachains]] + +[types.Header] +number = "u64" +parent_hash = "Hash" +post_state = "Hash"