Fix several issues found throughout the test suite.

The test suite has been broken for a while, due to a variety of issues,
ranging from lack of valid configuration for certain tools to bad temp
directories, to path mismatch issues on MacOS X.

This fixes all the unit tests, getting us back to 100% test coverage,
where we are never allowed to leave again.