It seems that calling Popen can return to the caller before the started process has read all the needed information
from its executable. This means that in case we delete the executable while the process is still starting up,
this test will create a zombie process which in turn leads to a failing test. On my macOS system this happens quite frequently.
The startup time for this process is really short, so waiting half a second before deleting the executable seems to be
long enough to make this test pass consistently.