Fix: Tests with racy event validation

Similar to d7ee608c00feacea3cfd5a740df64e5215347cb9, make sure that
the event validation scheme is not racy. If we need to wait for applications
to complete simply start them in foreground or use the built-in 'wait'
command in bash to wait for applications started in background.

Signed-off-by: Christian Babeux <christian.babeux@efficios.com>