added tempfile for snapshot tests