Move Process.kill to an after hook so it runs consistently.