mroth/lolcommits — pull request #110 by matthutchinson (2013-07-19 16:04:46+00:00)
Title: Adding a better feature for testing the --fork option

Adding the concept of an lolcommits.pid file to hold the child process id when running with the --fork option (introduced in this previous PR `https://github.com/mroth/lolcommits/pull/109`)

With a pid file, it is possible to test that the child process has exited in `lolcommits.feature`. A new step waits for the file to be removed. To allow command output step to work, `$stdout.sync = true` is set before forking.

I don't really like using the `sleep` call in the new step. I really wanted to use `Process.waitpid()` but because the feature runs in a different process it isn't possible. If you can think of a better way to do this, maybe without the pid file, or without the sleep - let me know.