Use createTempFile for tests instead of a hardcoded test file name.