-
Notifications
You must be signed in to change notification settings - Fork 92
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: added new smoke test aggregation of multiple tests for podman ci
- Loading branch information
Showing
4 changed files
with
84 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
async function run(nodeName, networkInfo, args) { | ||
const {wsUri, userDefinedTypes} = networkInfo.nodesByName[nodeName]; | ||
const api = await zombie.connect(wsUri, userDefinedTypes); | ||
const validator = await api.query.session.validators(); | ||
return validator.length; | ||
} | ||
|
||
module.exports = { run } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# just echo for this test | ||
echo "OK" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
# cover 0002 / 0006 / 0007 / 0008 / 0010 / 0011 | ||
[settings] | ||
timeout = 1000 | ||
|
||
[relaychain] | ||
default_image = "{{ZOMBIENET_INTEGRATION_TEST_IMAGE}}" | ||
chain = "rococo-local" | ||
command = "polkadot" | ||
|
||
[relaychain.genesis.runtime.runtime_genesis_config.configuration.config] | ||
max_validators_per_core = 2 | ||
needed_approvals = 2 | ||
|
||
|
||
[[relaychain.nodes]] | ||
name = "alice" | ||
|
||
[[relaychain.nodes]] | ||
name = "bob" | ||
|
||
[[parachains]] | ||
id = 100 | ||
add_to_genesis = true | ||
|
||
[parachains.collator] | ||
name = "collator01" | ||
image = "{{COL_IMAGE}}" | ||
command = "adder-collator" | ||
|
||
[types.Header] | ||
number = "u64" | ||
parent_hash = "Hash" | ||
post_state = "Hash" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
Description: Smoke Test | ||
Network: ./0001-smoke.toml | ||
Creds: config | ||
|
||
alice: is up | ||
bob: is up | ||
|
||
# Logs assertions | ||
alice: reports block height is at least 4 within 200 seconds | ||
alice: log line contains "Imported #2" within 20 seconds | ||
alice: log line matches glob "*rted #1*" within 10 seconds | ||
alice: log line matches "Imported #[0-9]+" within 10 seconds | ||
alice: count of log lines containing "imported" is at least 4 within 10 seconds | ||
|
||
|
||
# Events assertions | ||
alice: system event contains "A candidate was included" within 60 seconds | ||
alice: system event matches glob "*was backed*" within 20 seconds | ||
alice: system event matches "paraId(.)*[0-9]+" within 20 seconds | ||
|
||
# Custom scripts | ||
alice: js-script ./0001-custom.js return is greater than 1 within 200 seconds | ||
alice: js-script ./0001-custom.js within 200 seconds | ||
alice: js-script ./0001-custom.js with "alice" within 200 seconds | ||
alice: run ./0001-custom.sh within 200 seconds | ||
|
||
# Histogram assertions | ||
alice: reports histogram polkadot_pvf_execution_time has at least 2 samples in buckets ["0.01"] within 100 seconds | ||
|
||
# restart / pause / resume | ||
bob: pause | ||
collator01: pause | ||
alice: is up | ||
alice: restart after 20 seconds | ||
sleep 25 seconds | ||
alice: is up | ||
alice: pause | ||
# Todo add `should fail` support | ||
# alice: is down | ||
alice: resume | ||
alice: is up within 120 seconds |