tests(fix): process_check_restart.bats - Run pgrep within the actual container (#3553)

This was missed during original review.

On a linux host, processes running within a container have been visible via commands like `pgrep`. This is does not appear to be the case with WSL2 + Docker Desktop (Windows), resulting in test failure.

The command should have been run from within the container regardless.
This commit is contained in:
Brennan Kinney 2023-09-29 01:37:15 +13:00 committed by GitHub
parent 8c0cfa0836
commit a9d6e329cd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -120,9 +120,9 @@ ENV_PROCESS_LIST=(
# By this point the fetchmail processes have been verified to exist and restart, # By this point the fetchmail processes have been verified to exist and restart,
# For FETCHMAIL_PARALLEL=1 coverage, match full commandline for COUNTER values: # For FETCHMAIL_PARALLEL=1 coverage, match full commandline for COUNTER values:
pgrep --full 'fetchmail-1.rc' _run_in_container pgrep --full 'fetchmail-1.rc'
assert_success assert_success
pgrep --full 'fetchmail-2.rc' _run_in_container pgrep --full 'fetchmail-2.rc'
assert_success assert_success
_should_stop_cleanly _should_stop_cleanly