diff --git a/tests/unit/test_download_from_mass_permissions.py b/tests/unit/test_download_from_mass_permissions.py index 1471121e..719a78fc 100644 --- a/tests/unit/test_download_from_mass_permissions.py +++ b/tests/unit/test_download_from_mass_permissions.py @@ -6,14 +6,16 @@ def test_allowed_user(): + user_home = os.path.expanduser('~') + output_folder = "bgcval2/local_test/BGC_data/u-xxx/" + run_dir = os.path.join(user_home, output_folder) + if not os.path.exists(run_dir): + os.makedirs(run_dir) dfm(jobID="u-xxx", doMoo=False, auto_download=False, config_user="defaults" ) - user_home = os.path.expanduser('~') - output_folder = "bgcval2/local_test/BGC_data/u-xxx/" - run_dir = os.path.join(user_home, output_folder) assert os.stat(run_dir).st_mode == 16893