Add CI for monorepo (#1145)

* Add CI for monorepo

* fix frame tests

* Format features

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* add note for skipping tests and disable test-linux-stable-all

* Fix tests and compile issues (#1152)

* Fix feature dependant import

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Bump test timeout

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Remove feature gate

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Add resolver 2

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Remove old lockfile

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Format features

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

---------

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Fix check-dependency-rules

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* rm test-runtime

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Actually fix script

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* enable cargo-check-each-crate-macos

* Run check-each-crate on 6 machines (#1163)

---------

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
This commit is contained in:
Alexander Samusev
2023-08-25 16:35:22 +02:00
committed by GitHub
parent 1a38d6d6be
commit e49493442a
157 changed files with 5001 additions and 18604 deletions
+143
View File
@@ -0,0 +1,143 @@
# This file is part of .gitlab-ci.yml
# Here are all jobs that are executed during "zombienet" stage
.zombienet-before-script:
before_script:
- echo "Zombie-net Tests Config"
- echo "${ZOMBIENET_IMAGE}"
- echo "${RELAY_IMAGE}"
- echo "${COL_IMAGE}"
- echo "${GH_DIR}"
- echo "${LOCAL_DIR}"
- export DEBUG=zombie
- export RELAY_IMAGE=${POLKADOT_IMAGE}
- export COL_IMAGE=${COL_IMAGE}
.zombienet-after-script:
after_script:
- mkdir -p ./zombienet-logs
- cp /tmp/zombie*/logs/* ./zombienet-logs/
# common settings for all zombienet jobs
.zombienet-cumulus-common:
stage: zombienet
image: "${ZOMBIENET_IMAGE}"
needs:
- job: build-push-image-test-parachain
artifacts: true
variables:
POLKADOT_IMAGE: "docker.io/paritypr/polkadot-debug:master"
GH_DIR: "https://github.com/paritytech/cumulus/tree/${CI_COMMIT_SHORT_SHA}/zombienet/tests"
LOCAL_DIR: "/builds/parity/mirrors/polkadot-sdk/cumulus/zombienet/tests"
COL_IMAGE: "docker.io/paritypr/test-parachain:${DOCKER_IMAGES_VERSION}"
FF_DISABLE_UMASK_FOR_DOCKER_EXECUTOR: 1
artifacts:
name: "${CI_JOB_NAME}_${CI_COMMIT_REF_NAME}"
when: always
expire_in: 2 days
paths:
- ./zombienet-logs
allow_failure: true
retry: 2
tags:
- zombienet-polkadot-integration-test
zombienet-cumulus-0001-sync_blocks_from_tip_without_connected_collator:
extends:
- .zombienet-cumulus-common
- .zombienet-refs
- .zombienet-before-script
- .zombienet-after-script
script:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
--local-dir="${LOCAL_DIR}"
--concurrency=1
--test="0001-sync_blocks_from_tip_without_connected_collator.zndsl"
zombienet-cumulus-0002-pov_recovery:
extends:
- .zombienet-cumulus-common
- .zombienet-refs
- .zombienet-before-script
- .zombienet-after-script
script:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
--local-dir="${LOCAL_DIR}"
--concurrency=1
--test="0002-pov_recovery.zndsl"
zombienet-cumulus-0003-full_node_catching_up:
extends:
- .zombienet-cumulus-common
- .zombienet-refs
- .zombienet-before-script
- .zombienet-after-script
script:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
--local-dir="${LOCAL_DIR}"
--concurrency=1
--test="0003-full_node_catching_up.zndsl"
zombienet-cumulus-0004-runtime_upgrade:
extends:
- .zombienet-cumulus-common
- .zombienet-refs
- .zombienet-before-script
- .zombienet-after-script
needs:
- !reference [.zombienet-cumulus-common, needs]
- job: build-test-parachain
artifacts: true
before_script:
- ls -ltr *
- cp ./artifacts/zombienet/wasm_binary_spec_version_incremented.rs.compact.compressed.wasm /tmp/
- ls /tmp
- !reference [.zombienet-before-script, before_script]
script:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
--local-dir="${LOCAL_DIR}"
--concurrency=1
--test="0004-runtime_upgrade.zndsl"
zombienet-cumulus-0005-migrate_solo_to_para:
extends:
- .zombienet-cumulus-common
- .zombienet-refs
- .zombienet-before-script
- .zombienet-after-script
needs:
- !reference [.zombienet-cumulus-common, needs]
- job: build-test-parachain
artifacts: true
before_script:
- ls -ltr *
- !reference [.zombienet-before-script, before_script]
script:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
--local-dir="${LOCAL_DIR}"
--concurrency=1
--test="0005-migrate_solo_to_para.zndsl"
zombienet-cumulus-0006-rpc_collator_builds_blocks:
extends:
- .zombienet-cumulus-common
- .zombienet-refs
- .zombienet-before-script
- .zombienet-after-script
script:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
--local-dir="${LOCAL_DIR}"
--concurrency=1
--test="0006-rpc_collator_builds_blocks.zndsl"
zombienet-cumulus-0007-full_node_warp_sync:
extends:
- .zombienet-cumulus-common
- .zombienet-refs
- .zombienet-before-script
- .zombienet-after-script
script:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
--local-dir="${LOCAL_DIR}"
--concurrency=1
--test="0007-full_node_warp_sync.zndsl"
+169
View File
@@ -0,0 +1,169 @@
# This file is part of .gitlab-ci.yml
# Here are all jobs that are executed during "zombienet" stage
# common settings for all zombienet jobs
.zombienet-polkadot-common:
before_script:
- export DEBUG=zombie,zombie::network-node
- export ZOMBIENET_INTEGRATION_TEST_IMAGE="${POLKADOT_IMAGE}":${PIPELINE_IMAGE_TAG}
- export COL_IMAGE="${COLANDER_IMAGE}":${PIPELINE_IMAGE_TAG}
- export MALUS_IMAGE="${MALUS_IMAGE}":${PIPELINE_IMAGE_TAG}
- echo "Zombienet Tests Config"
- echo "gh-dir ${GH_DIR}"
- echo "local-dir ${LOCAL_DIR}"
- echo "polkadot image ${ZOMBIENET_INTEGRATION_TEST_IMAGE}"
- echo "colander image ${COL_IMAGE}"
- echo "malus image ${MALUS_IMAGE}"
stage: zombienet
image: "${ZOMBIENET_IMAGE}"
needs:
- job: build-push-image-malus
artifacts: true
- job: build-push-image-polkadot-debug
artifacts: true
- job: build-push-image-colander
artifacts: true
extends:
- .kubernetes-env
- .zombienet-refs
variables:
PIPELINE_IMAGE_TAG: ${DOCKER_IMAGES_VERSION}
POLKADOT_IMAGE: "docker.io/paritypr/polkadot-debug"
COLANDER_IMAGE: "docker.io/paritypr/colander"
MALUS_IMAGE: "docker.io/paritypr/malus"
GH_DIR: "https://github.com/paritytech/substrate/tree/${CI_COMMIT_SHA}/zombienet"
LOCAL_DIR: "/builds/parity/mirrors/polkadot-sdk/polkadot/zombienet_tests"
FF_DISABLE_UMASK_FOR_DOCKER_EXECUTOR: 1
artifacts:
name: "${CI_JOB_NAME}_${CI_COMMIT_REF_NAME}"
when: always
expire_in: 2 days
paths:
- ./zombienet-logs
after_script:
- mkdir -p ./zombienet-logs
- cp /tmp/zombie*/logs/* ./zombienet-logs/
retry: 2
tags:
- zombienet-polkadot-integration-test
zombienet-polkadot-functional-0001-parachains-pvf:
extends:
- .zombienet-polkadot-common
script:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
--local-dir="${LOCAL_DIR}/functional"
--test="0001-parachains-pvf.zndsl"
zombienet-polkadot-functional-0002-parachains-disputes:
extends:
- .zombienet-polkadot-common
script:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
--local-dir="${LOCAL_DIR}/functional"
--test="0002-parachains-disputes.zndsl"
zombienet-polkadot-functional-0003-parachains-disputes-garbage-candidate:
extends:
- .zombienet-polkadot-common
script:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
--local-dir="${LOCAL_DIR}/functional"
--test="0003-parachains-garbage-candidate.zndsl"
zombienet-polkadot-functional-0004-beefy-and-mmr:
extends:
- .zombienet-polkadot-common
script:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
--local-dir="${LOCAL_DIR}/functional"
--test="0003-beefy-and-mmr.zndsl"
zombienet-polkadot-smoke-0001-parachains-smoke-test:
extends:
- .zombienet-polkadot-common
before_script:
- export ZOMBIENET_INTEGRATION_TEST_IMAGE="${POLKADOT_IMAGE}":${PIPELINE_IMAGE_TAG}
- export COL_IMAGE="docker.io/paritypr/colander:4519" # The collator image is fixed
- echo "Zombienet Tests Config"
- echo "gh-dir ${GH_DIR}"
- echo "local-dir ${LOCAL_DIR}"
- echo "polkadot image ${ZOMBIENET_INTEGRATION_TEST_IMAGE}"
- echo "colander image ${COL_IMAGE}"
- echo "malus image ${MALUS_IMAGE}"
script:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
--local-dir="${LOCAL_DIR}/smoke"
--test="0001-parachains-smoke-test.zndsl"
zombienet-polkadot-smoke-0002-parachains-parachains-upgrade-smoke:
extends:
- .zombienet-polkadot-common
before_script:
- export ZOMBIENET_INTEGRATION_TEST_IMAGE="${POLKADOT_IMAGE}":${PIPELINE_IMAGE_TAG}
- export COL_IMAGE="docker.io/parity/polkadot-collator:latest" # Use cumulus lastest image
- echo "Zombienet Tests Config"
- echo "gh-dir ${GH_DIR}"
- echo "local-dir ${LOCAL_DIR}"
- echo "polkadot image ${ZOMBIENET_INTEGRATION_TEST_IMAGE}"
- echo "colander image ${COL_IMAGE}"
- echo "malus image ${MALUS_IMAGE}"
script:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
--local-dir="${LOCAL_DIR}/smoke"
--test="0002-parachains-upgrade-smoke-test.zndsl"
zombienet-polkadot-smoke-0003-deregister-register-validator:
extends:
- .zombienet-polkadot-common
script:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
--local-dir="${LOCAL_DIR}/smoke"
--test="0003-deregister-register-validator-smoke.zndsl"
zombienet-polkadot-misc-0001-parachains-paritydb:
extends:
- .zombienet-polkadot-common
script:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
--local-dir="${LOCAL_DIR}/misc"
--test="0001-paritydb.zndsl"
zombienet-polkadot-misc-0002-upgrade-node:
extends:
- .zombienet-polkadot-common
needs:
- job: build-push-image-malus
artifacts: true
- job: build-push-image-polkadot-debug
artifacts: true
- job: build-push-image-colander
artifacts: true
- job: build-linux-stable
artifacts: true
before_script:
- export ZOMBIENET_INTEGRATION_TEST_IMAGE="docker.io/parity/polkadot:latest"
- echo "Overrided poladot image ${ZOMBIENET_INTEGRATION_TEST_IMAGE}"
- export COL_IMAGE="${COLANDER_IMAGE}":${PIPELINE_IMAGE_TAG}
- BUILD_LINUX_JOB_ID="$(cat ./artifacts/BUILD_LINUX_JOB_ID)"
- export POLKADOT_PR_BIN_URL="https://gitlab-stg.parity.io/parity/mirrors/polkadot-sdk/-/jobs/${BUILD_LINUX_JOB_ID}/artifacts/raw/artifacts/polkadot"
- echo "Zombienet Tests Config"
- echo "gh-dir ${GH_DIR}"
- echo "local-dir ${LOCAL_DIR}"
- echo "polkadot image ${ZOMBIENET_INTEGRATION_TEST_IMAGE}"
- echo "colander image ${COL_IMAGE}"
- echo "malus image ${MALUS_IMAGE}"
script:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
--local-dir="${LOCAL_DIR}/misc"
--test="0002-upgrade-node.zndsl"
zombienet-polkadot-malus-0001-dispute-valid:
extends:
- .zombienet-polkadot-common
variables:
LOCAL_DIR: "/builds/parity/mirrors/polkadot-sdk/polkadot/node/malus"
script:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
--local-dir="${LOCAL_DIR}/integrationtests"
--test="0001-dispute-valid-block.zndsl"
+70
View File
@@ -0,0 +1,70 @@
# This file is part of .gitlab-ci.yml
# Here are all jobs that are executed during "zombienet" stage
# common settings for all zombienet jobs
.zombienet-substrate-common:
before_script:
- echo "Zombienet Tests Config"
- echo "${ZOMBIENET_IMAGE}"
- echo "${GH_DIR}"
- echo "${LOCAL_DIR}"
- export DEBUG=zombie,zombie::network-node
- export ZOMBIENET_INTEGRATION_TEST_IMAGE="${SUBSTRATE_IMAGE}":${SUBSTRATE_IMAGE_TAG}
- echo "${ZOMBIENET_INTEGRATION_TEST_IMAGE}"
stage: zombienet
image: "${ZOMBIENET_IMAGE}"
needs:
- job: build-push-image-substrate-pr
extends:
- .kubernetes-env
- .zombienet-refs
variables:
SUBSTRATE_IMAGE_TAG: ${DOCKER_IMAGES_VERSION}
SUBSTRATE_IMAGE: "docker.io/paritypr/substrate"
GH_DIR: "https://github.com/paritytech/substrate/tree/${CI_COMMIT_SHA}/zombienet"
LOCAL_DIR: "/builds/parity/mirrors/polkadot-sdk/substrate/zombienet"
FF_DISABLE_UMASK_FOR_DOCKER_EXECUTOR: 1
artifacts:
name: "${CI_JOB_NAME}_${CI_COMMIT_REF_NAME}"
when: always
expire_in: 2 days
paths:
- ./zombienet-logs
after_script:
- mkdir -p ./zombienet-logs
- cp /tmp/zombie*/logs/* ./zombienet-logs/
retry: 2
tags:
- zombienet-polkadot-integration-test
zombienet-substrate-0000-block-building:
extends:
- .zombienet-substrate-common
script:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
--local-dir="${LOCAL_DIR}/0000-block-building"
--test="block-building.zndsl"
zombienet-substrate-0001-basic-warp-sync:
extends:
- .zombienet-substrate-common
script:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
--local-dir="${LOCAL_DIR}/0001-basic-warp-sync"
--test="test-warp-sync.zndsl"
zombienet-substrate-0002-validators-warp-sync:
extends:
- .zombienet-substrate-common
script:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
--local-dir="${LOCAL_DIR}/0002-validators-warp-sync"
--test="test-validators-warp-sync.zndsl"
zombienet-substrate-0003-block-building-warp-sync:
extends:
- .zombienet-substrate-common
script:
- /home/nonroot/zombie-net/scripts/ci/run-test-local-env-manager.sh
--local-dir="${LOCAL_DIR}/0003-block-building-warp-sync"
--test="test-block-building-warp-sync.zndsl"