diff options
| author | Paweł Stołowski <stolowski@gmail.com> | 2021-09-15 14:54:43 +0200 |
|---|---|---|
| committer | Paweł Stołowski <stolowski@gmail.com> | 2021-09-27 17:21:12 +0200 |
| commit | e8ac5d9d7294055ace3538104822d66ec61b1d54 (patch) | |
| tree | d8e1673c79162a23bf17845e1e3de410ec6efcea | |
| parent | d2b75a6d82e65c8fa2fa63f1cdddc84dc66d856e (diff) | |
Report stray tasks in spread test restore.
| -rwxr-xr-x | tests/lib/prepare-restore.sh | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/lib/prepare-restore.sh b/tests/lib/prepare-restore.sh index d655f88f0e..a62c6c527a 100755 --- a/tests/lib/prepare-restore.sh +++ b/tests/lib/prepare-restore.sh @@ -740,6 +740,12 @@ restore_suite() { } restore_project_each() { + $STRAY_TASKS=$(cat /var/lib/snapd/state.json | jq '.tasks[] | select (.change == "") | {"id":.id,"summary":.summary,"kind":.kind}') + if [ $(echo "$STRAY_TASKS" | wc -l) -gt 0 ]; then + echo "$STRAY_TASKS" + exit 1 + fi + "$TESTSTOOLS"/cleanup-state pre-invariant # Check for invariants early, in order not to mask bugs in tests. tests.invariant check |
