2828def setup_config (tmpdir : py .path .local ):
2929 config_path = tmpdir .mkdir ("configs" ).join ("CLIENT_ID" )
3030 os .environ ["MAPILLARY_CONFIG_PATH" ] = str (config_path )
31+ os .environ ["MAPILLARY_TOOLS__DISABLE_AUTH_VERIFICATION" ] = "YES"
3132 x = subprocess .run (
3233 f"{ EXECUTABLE } authenticate --user_name { USERNAME } --jwt test_user_token" ,
3334 shell = True ,
@@ -36,7 +37,8 @@ def setup_config(tmpdir: py.path.local):
3637 yield config_path
3738 if tmpdir .check ():
3839 tmpdir .remove (ignore_errors = True )
39- del os .environ ["MAPILLARY_CONFIG_PATH" ]
40+ os .environ .pop ("MAPILLARY_CONFIG_PATH" , None )
41+ os .environ .pop ("MAPILLARY_TOOLS__DISABLE_AUTH_VERIFICATION" , None )
4042
4143
4244@pytest .fixture
@@ -53,15 +55,17 @@ def setup_data(tmpdir: py.path.local):
5355def setup_upload (tmpdir : py .path .local ):
5456 upload_dir = tmpdir .mkdir ("mapillary_public_uploads" )
5557 os .environ ["MAPILLARY_UPLOAD_PATH" ] = str (upload_dir )
58+ os .environ ["MAPILLARY_TOOLS__DISABLE_AUTH_VERIFICATION" ] = "YES"
5659 os .environ ["MAPILLARY__ENABLE_UPLOAD_HISTORY_FOR_DRY_RUN" ] = "YES"
5760 history_path = tmpdir .join ("history" )
5861 os .environ ["MAPILLARY_UPLOAD_HISTORY_PATH" ] = str (history_path )
5962 yield upload_dir
6063 if tmpdir .check ():
6164 tmpdir .remove (ignore_errors = True )
62- del os .environ ["MAPILLARY_UPLOAD_PATH" ]
63- del os .environ ["MAPILLARY_UPLOAD_HISTORY_PATH" ]
64- del os .environ ["MAPILLARY__ENABLE_UPLOAD_HISTORY_FOR_DRY_RUN" ]
65+ os .environ .pop ("MAPILLARY_UPLOAD_PATH" , None )
66+ os .environ .pop ("MAPILLARY_UPLOAD_HISTORY_PATH" , None )
67+ os .environ .pop ("MAPILLARY_TOOLS__DISABLE_AUTH_VERIFICATION" , None )
68+ os .environ .pop ("MAPILLARY__ENABLE_UPLOAD_HISTORY_FOR_DRY_RUN" , None )
6569
6670
6771def _ffmpeg_installed ():
0 commit comments