MCPcopy Create free account
hub / github.com/apache/arrow / test_download_tzdata_on_windows

Function test_download_tzdata_on_windows

python/pyarrow/tests/test_util.py:217–230  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

215@pytest.mark.skipif(sys.platform != "win32",
216 reason="Timezone database is already provided.")
217def test_download_tzdata_on_windows():
218 tzdata_path = os.path.expandvars(r"%USERPROFILE%\Downloads\tzdata")
219
220 # Download timezone database and remove data in case it already exists
221 if (os.path.exists(tzdata_path)):
222 shutil.rmtree(tzdata_path)
223 with pytest.warns(FutureWarning, match="deprecated"):
224 download_tzdata_on_windows()
225
226 # Inspect the folder
227 assert os.path.exists(tzdata_path)
228 assert os.path.exists(os.path.join(tzdata_path, "windowsZones.xml"))
229 assert os.path.exists(os.path.join(tzdata_path, "europe"))
230 assert 'version' in os.listdir(tzdata_path)

Callers

nothing calls this directly

Calls 2

joinMethod · 0.45

Tested by

no test coverage detected