@@ -416,14 +416,14 @@ def test_observations_filter_products(self):
416
416
assert isinstance (result , Table )
417
417
assert len (result ) == sum (products ['productType' ] == "SCIENCE" )
418
418
419
- def test_observations_download_products (self , tmpdir ):
419
+ def test_observations_download_products (self , tmp_path ):
420
420
def check_filepath (path ):
421
421
assert os .path .isfile (path )
422
422
os .remove (path )
423
423
424
424
test_obs_id = '25119363'
425
425
result = Observations .download_products (test_obs_id ,
426
- download_dir = str ( tmpdir ) ,
426
+ download_dir = tmp_path ,
427
427
productType = ["SCIENCE" ],
428
428
mrp_only = False )
429
429
assert isinstance (result , Table )
@@ -433,7 +433,7 @@ def check_filepath(path):
433
433
434
434
# just get the curl script
435
435
result = Observations .download_products (test_obs_id ,
436
- download_dir = str ( tmpdir ) ,
436
+ download_dir = tmp_path ,
437
437
curl_flag = True ,
438
438
productType = ["SCIENCE" ],
439
439
mrp_only = False )
@@ -442,7 +442,8 @@ def check_filepath(path):
442
442
443
443
# check for row input
444
444
result1 = Observations .get_product_list (test_obs_id )
445
- result2 = Observations .download_products (result1 [0 ])
445
+ result2 = Observations .download_products (result1 [0 ],
446
+ download_dir = tmp_path )
446
447
assert isinstance (result2 , Table )
447
448
check_filepath (result2 ['Local Path' ][0 ])
448
449
assert len (result2 ) == 1
0 commit comments