Manually resolve symlinks in test helpers

Mac OS X's `readlink` command does not support the same options as GNU,
FreeBSD, and other operating systems, nor does it support canonicalizing
symlink resolutions.

In place of `readlink`, we're going to borrow [this] suggested implementation
from the community.

[this]: 
http://stackoverflow.com/questions/1055671/how-can-i-get-the-behavior-of-gnus-readlink-f-on-a-mac
Fair enough. The other helpers are assertions, where the exit code is more important (it determines if the test passes). That said, they probably don't need it either.