Consistently use File.getCanonicalPath() to avoid mismatch on MacOSX

Updating tests to use File.getCanonicalPath() instead of File.getAbsolutePath(), since that was causing a mismatch on MacOSX where temp files are located in /var by default.  Since /var is a symlink to /private/var, the absolute and canonical paths don't match.