ZTS: normalize on use of sync_pool and sync_all_pools

- Replaces use of manual `zpool sync`
- Don't use `log_must sync_pool` as `sync_pool` uses it internally
- Replace many (but not all) uses of `sync` with `sync_pool`

This makes the tests more consistent, and makes searching easier.

Reviewed-by: George Melikov <mail@gmelikov.ru>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Allan Jude <allan@klarasystems.com>
Closes #12894
This commit is contained in:
Allan Jude
2022-01-06 13:57:09 -05:00
committed by GitHub
parent 6b2e32019e
commit 7454275a53
95 changed files with 148 additions and 118 deletions
@@ -90,7 +90,8 @@ for disk in $DISKLIST; do
done
log_must kill $killpid
sync
sync_all_pools
log_must sync
typeset dir=$(get_device_dir $DISKS)
verify_filesys "$TESTPOOL" "$TESTPOOL/$TESTFS" "$dir"
@@ -129,7 +129,8 @@ while [[ $i -lt ${#disks[*]} ]]; do
done
log_must kill $killpid
sync
sync_all_pools
log_must sync
typeset dir=$(get_device_dir $DISKS)
verify_filesys "$TESTPOOL" "$TESTPOOL/$TESTFS" "$dir"
@@ -76,6 +76,6 @@ for i in 0 1 2; do
done
log_must kill $killpid
sync
sync_all_pools
log_pass