mirror of
https://github.com/troglobit/finit.git
synced 2026-10-29 12:40:44 +00:00
test: Minor refactor to reduce test code duplication
Signed-off-by: Magnus Malm <magnusmalm@gmail.com>
This commit is contained in:
1 parent
6027e94c65
commit
f214098560
5 files changed
+4
-16
No files matched your search
@@ -1,5 +1,9 @@
|
||||
#!/bin/sh
|
||||
|
||||
assert_num_children() {
|
||||
assert "$1 services are running" "$(texec pgrep -P 1 "$2" | wc -l)" -eq "$1"
|
||||
}
|
||||
|
||||
texec() {
|
||||
# shellcheck disable=SC2154
|
||||
"$TEST_DIR/testenv_exec.sh" "$finit_pid" "$@"
|
||||
|
||||
Reference in new issue
Block a user