Skip to content

Commit

Permalink
Test: add test for #1084
Browse files Browse the repository at this point in the history
  • Loading branch information
agoose77 committed Sep 9, 2021
1 parent 688a160 commit 9dda72d
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions tests/test_1084-from-json-win-path.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# BSD 3-Clause License; see https://github.com/scikit-hep/awkward-1.0/blob/main/LICENSE
from __future__ import absolute_import
import pytest # noqa: F401
import numpy as np # noqa: F401
import awkward as ak # noqa: F401
import urllib.request
import urllib.error


@pytest.mark.skipif(not ak._util.win, reason="requires Windows")
def test():
url = "https://raw.githubusercontent.com/Chicago/osd-bike-routes/master/data/Bikeroutes.geojson"
try:
bikeroutes_json = urllib.request.urlopen(url).read()
except urllib.error.URLError:
pytest.skip(reason="couldn't download sample dataset")

# This shouldn't fail (see #1084)
ak.from_json(bikeroutes_json)

0 comments on commit 9dda72d

Please sign in to comment.