From 39e55ffd0ad4b5fa29bfc95b72214cec88fc310b Mon Sep 17 00:00:00 2001
From: Nikos Kontakis <wirednkod@gmail.com>
Date: Thu, 29 Sep 2022 10:22:15 +0300
Subject: [PATCH] Rename zombienet extension (#6073)

* Rename extension files and respective entries from '.feature' to '.zndsl'

* Rename zombienet extension for 0001-dispute-valid-block test
---
 polkadot/node/malus/README.md                 |  6 ++---
 ...feature => 0001-dispute-valid-block.zndsl} |  0
 .../scripts/ci/gitlab/pipeline/zombienet.yml  | 22 +++++++++----------
 polkadot/zombienet_tests/README.md            |  5 +++--
 ...-pvf.feature => 0001-parachains-pvf.zndsl} |  0
 ...feature => 0002-parachains-disputes.zndsl} |  0
 ...d-mmr.feature => 0003-beefy-and-mmr.zndsl} |  0
 ...> 0003-parachains-garbage-candidate.zndsl} |  0
 ...1-paritydb.feature => 0001-paritydb.zndsl} |  0
 .../misc/0002-download-polkadot-from-pr.sh    |  2 +-
 ...e-node.feature => 0002-upgrade-node.zndsl} |  0
 ...ature => 0001-parachains-smoke-test.zndsl} |  0
 ... 0002-parachains-upgrade-smoke-test.zndsl} |  0
 ...deregister-register-validator-smoke.zndsl} |  0
 14 files changed, 18 insertions(+), 17 deletions(-)
 rename polkadot/node/malus/integrationtests/{0001-dispute-valid-block.feature => 0001-dispute-valid-block.zndsl} (100%)
 rename polkadot/zombienet_tests/functional/{0001-parachains-pvf.feature => 0001-parachains-pvf.zndsl} (100%)
 rename polkadot/zombienet_tests/functional/{0002-parachains-disputes.feature => 0002-parachains-disputes.zndsl} (100%)
 rename polkadot/zombienet_tests/functional/{0003-beefy-and-mmr.feature => 0003-beefy-and-mmr.zndsl} (100%)
 rename polkadot/zombienet_tests/functional/{0003-parachains-garbage-candidate.feature => 0003-parachains-garbage-candidate.zndsl} (100%)
 rename polkadot/zombienet_tests/misc/{0001-paritydb.feature => 0001-paritydb.zndsl} (100%)
 rename polkadot/zombienet_tests/misc/{0002-upgrade-node.feature => 0002-upgrade-node.zndsl} (100%)
 rename polkadot/zombienet_tests/smoke/{0001-parachains-smoke-test.feature => 0001-parachains-smoke-test.zndsl} (100%)
 rename polkadot/zombienet_tests/smoke/{0002-parachains-upgrade-smoke-test.feature => 0002-parachains-upgrade-smoke-test.zndsl} (100%)
 rename polkadot/zombienet_tests/smoke/{0003-deregister-register-validator-smoke.feature => 0003-deregister-register-validator-smoke.zndsl} (100%)

diff --git a/polkadot/node/malus/README.md b/polkadot/node/malus/README.md
index 4f71016d77b..fb4bb0cd272 100644
--- a/polkadot/node/malus/README.md
+++ b/polkadot/node/malus/README.md
@@ -13,8 +13,8 @@ The first argument determines the behavior strain. The currently supported are:
 To define integration tests create file
 in the toml format as used with [zombienet][zombienet]
 under `./integrationtests` describing the network to spawn and
-also the `feature` file (with `.feature` extension ) using the format
-defined in the [DSL doc](https://github.com/paritytech/zombienet/blob/main/docs/testing-dsl-definition.md).
+also the `zndsl` file (with `.zndsl` extension ) using the format
+defined in the [(DSL[(**D**omain **S**pecific **L**anguage)]) doc](https://paritytech.github.io/zombienet/cli/test-dsl-definition-spec.html).
 
 ## Usage
 
@@ -37,7 +37,7 @@ gcloud container clusters get-credentials "parity-zombienet" --zone "europe-west
 # launching the actual test
 cd zombienet
 npm run build
-node dist/cli.js test <path to polkadot repo>/node/malus/integrationtests/0001-dispute-valid-block.feature
+node dist/cli.js test <path to polkadot repo>/node/malus/integrationtests/0001-dispute-valid-block.zndsl
 
 # Access  logs (in google cloud storage)
 gsutil ls gs://zombienet-logs/zombie-<namespace uniqueId>/logs/
diff --git a/polkadot/node/malus/integrationtests/0001-dispute-valid-block.feature b/polkadot/node/malus/integrationtests/0001-dispute-valid-block.zndsl
similarity index 100%
rename from polkadot/node/malus/integrationtests/0001-dispute-valid-block.feature
rename to polkadot/node/malus/integrationtests/0001-dispute-valid-block.zndsl
diff --git a/polkadot/scripts/ci/gitlab/pipeline/zombienet.yml b/polkadot/scripts/ci/gitlab/pipeline/zombienet.yml
index 8f7c5ef38a4..5c6215aad2c 100644
--- a/polkadot/scripts/ci/gitlab/pipeline/zombienet.yml
+++ b/polkadot/scripts/ci/gitlab/pipeline/zombienet.yml
@@ -26,7 +26,7 @@ zombienet-tests-parachains-smoke-test:
   script:
     - /home/nonroot/zombie-net/scripts/ci/run-test-env-manager.sh
         --github-remote-dir="${GH_DIR}"
-        --test="0001-parachains-smoke-test.feature"
+        --test="0001-parachains-smoke-test.zndsl"
   allow_failure:                   false
   retry: 2
   tags:
@@ -56,7 +56,7 @@ zombienet-tests-parachains-pvf:
   script:
     - /home/nonroot/zombie-net/scripts/ci/run-test-env-manager.sh
         --github-remote-dir="${GH_DIR}"
-        --test="0001-parachains-pvf.feature"
+        --test="0001-parachains-pvf.zndsl"
   allow_failure:                   false
   retry: 2
   tags:
@@ -87,7 +87,7 @@ zombienet-tests-parachains-disputes:
   script:
     - /home/nonroot/zombie-net/scripts/ci/run-test-env-manager.sh
         --github-remote-dir="${GH_DIR}"
-        --test="0002-parachains-disputes.feature"
+        --test="0002-parachains-disputes.zndsl"
   allow_failure:                   false
   retry: 2
   tags:
@@ -118,7 +118,7 @@ zombienet-tests-parachains-disputes-garbage-candidate:
   script:
     - /home/nonroot/zombie-net/scripts/ci/run-test-env-manager.sh
         --github-remote-dir="${GH_DIR}"
-        --test="0003-parachains-garbage-candidate.feature"
+        --test="0003-parachains-garbage-candidate.zndsl"
   allow_failure:                   false
   retry: 2
   tags:
@@ -148,7 +148,7 @@ zombienet-test-parachains-upgrade-smoke-test:
   script:
     - /home/nonroot/zombie-net/scripts/ci/run-test-env-manager.sh
         --github-remote-dir="${GH_DIR}"
-        --test="0002-parachains-upgrade-smoke-test.feature"
+        --test="0002-parachains-upgrade-smoke-test.zndsl"
   allow_failure:                   true
   retry: 2
   tags:
@@ -177,7 +177,7 @@ zombienet-tests-misc-paritydb:
   script:
     - /home/nonroot/zombie-net/scripts/ci/run-test-env-manager.sh
         --github-remote-dir="${GH_DIR}"
-        --test="0001-paritydb.feature"
+        --test="0001-paritydb.zndsl"
   allow_failure:                   false
   retry: 2
   tags:
@@ -210,7 +210,7 @@ zombienet-tests-misc-upgrade-node:
   script:
     - /home/nonroot/zombie-net/scripts/ci/run-test-env-manager.sh
         --github-remote-dir="${GH_DIR}"
-        --test="0002-upgrade-node.feature"
+        --test="0002-upgrade-node.zndsl"
   allow_failure:                   false
   retry: 2
   tags:
@@ -241,7 +241,7 @@ zombienet-tests-malus-dispute-valid:
   script:
     - /home/nonroot/zombie-net/scripts/ci/run-test-env-manager.sh
         --github-remote-dir="${GH_DIR}"
-        --test="0001-dispute-valid-block.feature"
+        --test="0001-dispute-valid-block.zndsl"
   allow_failure:                   false
   retry: 2
   tags:
@@ -269,7 +269,7 @@ zombienet-tests-deregister-register-validator:
   script:
     - /home/nonroot/zombie-net/scripts/ci/run-test-env-manager.sh
         --github-remote-dir="${GH_DIR}"
-        --test="0003-deregister-register-validator-smoke.feature"
+        --test="0003-deregister-register-validator-smoke.zndsl"
   allow_failure:                   false
   retry: 2
   tags:
@@ -295,8 +295,8 @@ zombienet-tests-beefy-and-mmr:
   script:
     - /home/nonroot/zombie-net/scripts/ci/run-test-env-manager.sh
       --github-remote-dir="${GH_DIR}"
-      --test="0003-beefy-and-mmr.feature"
+      --test="0003-beefy-and-mmr.zndsl"
   allow_failure:                   true
   retry: 2
   tags:
-    - zombienet-polkadot-integration-test
\ No newline at end of file
+    - zombienet-polkadot-integration-test
diff --git a/polkadot/zombienet_tests/README.md b/polkadot/zombienet_tests/README.md
index 2c732a6801d..5760e203d95 100644
--- a/polkadot/zombienet_tests/README.md
+++ b/polkadot/zombienet_tests/README.md
@@ -7,10 +7,11 @@ _The content of this directory is meant to be used by Parity's private CI/CD inf
 `parachains`
     At the moment this directory only have one test related to parachains: `/parachains-smoke-test`, that check the parachain registration and the block height.
 
-## Resources (private)
+## Resources
 
 * [zombienet repo](https://github.com/paritytech/zombienet)
+* [zombienet book](https://paritytech.github.io/zombienet/)
 
 ## Questions / permissions
 
-Ping in element [Javier](@javier:matrix.parity.io) to ask questions or grant permission to run the test from your local setup.
+Ping in element Javier (@javier:matrix.parity.io) to ask questions or grant permission to run the test from your local setup.
diff --git a/polkadot/zombienet_tests/functional/0001-parachains-pvf.feature b/polkadot/zombienet_tests/functional/0001-parachains-pvf.zndsl
similarity index 100%
rename from polkadot/zombienet_tests/functional/0001-parachains-pvf.feature
rename to polkadot/zombienet_tests/functional/0001-parachains-pvf.zndsl
diff --git a/polkadot/zombienet_tests/functional/0002-parachains-disputes.feature b/polkadot/zombienet_tests/functional/0002-parachains-disputes.zndsl
similarity index 100%
rename from polkadot/zombienet_tests/functional/0002-parachains-disputes.feature
rename to polkadot/zombienet_tests/functional/0002-parachains-disputes.zndsl
diff --git a/polkadot/zombienet_tests/functional/0003-beefy-and-mmr.feature b/polkadot/zombienet_tests/functional/0003-beefy-and-mmr.zndsl
similarity index 100%
rename from polkadot/zombienet_tests/functional/0003-beefy-and-mmr.feature
rename to polkadot/zombienet_tests/functional/0003-beefy-and-mmr.zndsl
diff --git a/polkadot/zombienet_tests/functional/0003-parachains-garbage-candidate.feature b/polkadot/zombienet_tests/functional/0003-parachains-garbage-candidate.zndsl
similarity index 100%
rename from polkadot/zombienet_tests/functional/0003-parachains-garbage-candidate.feature
rename to polkadot/zombienet_tests/functional/0003-parachains-garbage-candidate.zndsl
diff --git a/polkadot/zombienet_tests/misc/0001-paritydb.feature b/polkadot/zombienet_tests/misc/0001-paritydb.zndsl
similarity index 100%
rename from polkadot/zombienet_tests/misc/0001-paritydb.feature
rename to polkadot/zombienet_tests/misc/0001-paritydb.zndsl
diff --git a/polkadot/zombienet_tests/misc/0002-download-polkadot-from-pr.sh b/polkadot/zombienet_tests/misc/0002-download-polkadot-from-pr.sh
index 332435aaeeb..7ff323d9c41 100644
--- a/polkadot/zombienet_tests/misc/0002-download-polkadot-from-pr.sh
+++ b/polkadot/zombienet_tests/misc/0002-download-polkadot-from-pr.sh
@@ -11,7 +11,7 @@ mkdir -p $CFG_DIR
 export PATH=$CFG_DIR:$PATH
 
 cd $CFG_DIR
-# see 0002-upgrade-node.feature to view the args.
+# see 0002-upgrade-node.zndsl to view the args.
 curl -L -O $1
 chmod +x $CFG_DIR/polkadot
 echo $(polkadot --version)
diff --git a/polkadot/zombienet_tests/misc/0002-upgrade-node.feature b/polkadot/zombienet_tests/misc/0002-upgrade-node.zndsl
similarity index 100%
rename from polkadot/zombienet_tests/misc/0002-upgrade-node.feature
rename to polkadot/zombienet_tests/misc/0002-upgrade-node.zndsl
diff --git a/polkadot/zombienet_tests/smoke/0001-parachains-smoke-test.feature b/polkadot/zombienet_tests/smoke/0001-parachains-smoke-test.zndsl
similarity index 100%
rename from polkadot/zombienet_tests/smoke/0001-parachains-smoke-test.feature
rename to polkadot/zombienet_tests/smoke/0001-parachains-smoke-test.zndsl
diff --git a/polkadot/zombienet_tests/smoke/0002-parachains-upgrade-smoke-test.feature b/polkadot/zombienet_tests/smoke/0002-parachains-upgrade-smoke-test.zndsl
similarity index 100%
rename from polkadot/zombienet_tests/smoke/0002-parachains-upgrade-smoke-test.feature
rename to polkadot/zombienet_tests/smoke/0002-parachains-upgrade-smoke-test.zndsl
diff --git a/polkadot/zombienet_tests/smoke/0003-deregister-register-validator-smoke.feature b/polkadot/zombienet_tests/smoke/0003-deregister-register-validator-smoke.zndsl
similarity index 100%
rename from polkadot/zombienet_tests/smoke/0003-deregister-register-validator-smoke.feature
rename to polkadot/zombienet_tests/smoke/0003-deregister-register-validator-smoke.zndsl
-- 
GitLab