CIL icon indicating copy to clipboard operation
CIL copied to clipboard

CIL unittests on windows test_dataexample.TestRemoteData

Open gfardell opened this issue 10 months ago • 0 comments

Tests fail on windows.

======================================================================
ERROR: test_download_data_input_n (test_dataexample.TestRemoteData)
Test the download_data function, when the user input is 'n' to 'are you sure you want to download data'
----------------------------------------------------------------------
Traceback (most recent call last):
  File "C:\Users\gemst\miniconda3\conda-bld\cil_1711549741423\_test_env\lib\unittest\mock.py", line 1379, in patched
    return func(*newargs, **newkeywargs)
  File "C:\Users\gemst\miniconda3\conda-bld\cil_1711549741423\test_tmp\Wrappers\Python\test\test_dataexample.py", line 208, in tesn
    with ZipFile(tf.name, mode='w') as zip_file:
  File "C:\Users\gemst\miniconda3\conda-bld\cil_1711549741423\_test_env\lib\zipfile.py", line 1253, in __init__
    self.fp = io.open(file, filemode)
PermissionError: [Errno 13] Permission denied: 'C:\\Users\\gemst\\AppData\\Local\\Temp\\tmpri850_xh.zip'

======================================================================
ERROR: test_download_data_input_y (test_dataexample.TestRemoteData)
Test the download_data function, when the user input is 'y' to 'are you sure you want to download data'
----------------------------------------------------------------------
Traceback (most recent call last):
  File "C:\Users\gemst\miniconda3\conda-bld\cil_1711549741423\_test_env\lib\unittest\mock.py", line 1379, in patched
    return func(*newargs, **newkeywargs)
  File "C:\Users\gemst\miniconda3\conda-bld\cil_1711549741423\test_tmp\Wrappers\Python\test\test_dataexample.py", line 241, in tesy
    with ZipFile(tf.name, mode='w') as zip_file:
  File "C:\Users\gemst\miniconda3\conda-bld\cil_1711549741423\_test_env\lib\zipfile.py", line 1253, in __init__
    self.fp = io.open(file, filemode)
PermissionError: [Errno 13] Permission denied: 'C:\\Users\\gemst\\AppData\\Local\\Temp\\tmpw_36863o.zip'

======================================================================
ERROR: test_unzip_remote_data (test_dataexample.TestRemoteData)
Test the _download_and_extract_data_from_url function correctly extracts files from a byte string
----------------------------------------------------------------------
Traceback (most recent call last):
  File "C:\Users\gemst\miniconda3\conda-bld\cil_1711549741423\_test_env\lib\unittest\mock.py", line 1379, in patched
    return func(*newargs, **newkeywargs)
  File "C:\Users\gemst\miniconda3\conda-bld\cil_1711549741423\test_tmp\Wrappers\Python\test\test_dataexample.py", line 181, in tesa
    with ZipFile(tf.name, mode='w') as zip_file:
  File "C:\Users\gemst\miniconda3\conda-bld\cil_1711549741423\_test_env\lib\zipfile.py", line 1253, in __init__
    self.fp = io.open(file, filemode)
PermissionError: [Errno 13] Permission denied: 'C:\\Users\\gemst\\AppData\\Local\\Temp\\tmplb35t82j.zip'

----------------------------------------------------------------------

gfardell avatar Mar 27 '24 14:03 gfardell