Uses which instead of hardcoded paths in doctests. Fixes #182, #183, #184