diff --git a/requirements/requirements.in b/requirements/requirements.in new file mode 100644 index 0000000..93f0995 --- /dev/null +++ b/requirements/requirements.in @@ -0,0 +1,2 @@ +click +-r ../task/requirements.txt \ No newline at end of file diff --git a/requirements/requirements.txt b/requirements/requirements.txt new file mode 100644 index 0000000..1c4bb83 --- /dev/null +++ b/requirements/requirements.txt @@ -0,0 +1,192 @@ +# +# This file is autogenerated by pip-compile with Python 3.8 +# by the following command: +# +# pip-compile --output-file=requirements/requirements.txt requirements/requirements.in +# +-e git+https://github.com/digital-land/digital-land-python.git#egg=digital-land + # via -r requirements/../task/requirements.txt +aiofiles==24.1.0 + # via datasette +annotated-types==0.7.0 + # via pydantic +anyio==4.4.0 + # via httpx +asgi-csrf==0.10 + # via datasette +asgiref==3.8.1 + # via datasette +canonicaljson==2.0.0 + # via digital-land +cchardet==2.1.7 + # via digital-land +certifi==2024.7.4 + # via + # httpcore + # httpx + # pyproj + # requests +charset-normalizer==3.3.2 + # via requests +click==8.1.7 + # via + # -r requirements/requirements.in + # click-default-group + # dask + # datasette + # digital-land + # uvicorn +click-default-group==1.2.4 + # via datasette +cloudpickle==3.0.0 + # via dask +dask==2023.5.0 + # via digital-land +dataclasses-json==0.6.7 + # via digital-land +datasette==0.64.8 + # via digital-land +duckdb==1.0.0 + # via digital-land +esridump==1.13.0 + # via digital-land +et-xmlfile==1.1.0 + # via openpyxl +exceptiongroup==1.2.2 + # via anyio +fsspec==2024.6.1 + # via dask +geojson==3.1.0 + # via digital-land +h11==0.14.0 + # via + # httpcore + # uvicorn +httpcore==1.0.5 + # via httpx +httpx==0.27.2 + # via datasette +hupper==1.12.1 + # via datasette +idna==3.8 + # via + # anyio + # httpx + # requests +importlib-metadata==8.4.0 + # via dask +isodate==0.6.1 + # via rdflib +itsdangerous==2.2.0 + # via + # asgi-csrf + # datasette +janus==1.0.0 + # via datasette +jinja2==3.1.4 + # via datasette +json-stream==2.3.2 + # via digital-land +json-stream-rs-tokenizer==0.4.26 + # via json-stream +locket==1.0.0 + # via partd +markupsafe==2.1.5 + # via jinja2 +marshmallow==3.22.0 + # via dataclasses-json +mergedeep==1.3.4 + # via datasette +mypy-extensions==1.0.0 + # via typing-inspect +numpy==1.24.4 + # via + # digital-land + # pandas + # shapely +openpyxl==3.1.5 + # via digital-land +packaging==24.1 + # via + # dask + # marshmallow +pandas==2.0.3 + # via digital-land +partd==1.4.1 + # via dask +pint==0.21.1 + # via datasette +pluggy==1.5.0 + # via datasette +pydantic==2.8.2 + # via digital-land +pydantic-core==2.20.1 + # via pydantic +pyparsing==3.1.4 + # via rdflib +pyproj==3.5.0 + # via digital-land +python-dateutil==2.9.0.post0 + # via pandas +python-multipart==0.0.9 + # via asgi-csrf +pytz==2024.1 + # via pandas +pyyaml==6.0.2 + # via + # dask + # datasette + # digital-land +rdflib==7.0.0 + # via sparqlwrapper +requests==2.32.3 + # via + # digital-land + # esridump +shapely==2.0.2 + # via digital-land +six==1.16.0 + # via + # esridump + # isodate + # python-dateutil +sniffio==1.3.1 + # via + # anyio + # httpx +sparqlwrapper==2.0.0 + # via digital-land +spatialite==0.0.3 + # via digital-land +toolz==0.12.1 + # via + # dask + # partd +typing-extensions==4.12.2 + # via + # annotated-types + # anyio + # asgiref + # janus + # pydantic + # pydantic-core + # typing-inspect + # uvicorn +typing-inspect==0.9.0 + # via dataclasses-json +tzdata==2024.1 + # via pandas +urllib3==2.2.2 + # via requests +uvicorn==0.30.6 + # via datasette +validators==0.33.0 + # via digital-land +xlrd==1.2.0 + # via digital-land +zipp==3.20.1 + # via importlib-metadata + +# The following packages are considered to be unsafe in a requirements file: +# pip +# setuptools diff --git a/requirements/test-requirements.in b/requirements/test-requirements.in new file mode 100644 index 0000000..f2578c6 --- /dev/null +++ b/requirements/test-requirements.in @@ -0,0 +1,2 @@ +-r requirements.txt +pytest \ No newline at end of file diff --git a/requirements/test-requirements.txt b/requirements/test-requirements.txt new file mode 100644 index 0000000..69c3428 --- /dev/null +++ b/requirements/test-requirements.txt @@ -0,0 +1,325 @@ +# +# This file is autogenerated by pip-compile with Python 3.8 +# by the following command: +# +# pip-compile --output-file=requirements/test-requirements.txt requirements/test-requirements.in +# +-e git+https://github.com/digital-land/digital-land-python.git#egg=digital-land + # via -r requirements/requirements.txt +aiofiles==24.1.0 + # via + # -r requirements/requirements.txt + # datasette +annotated-types==0.7.0 + # via + # -r requirements/requirements.txt + # pydantic +anyio==4.4.0 + # via + # -r requirements/requirements.txt + # httpx +asgi-csrf==0.10 + # via + # -r requirements/requirements.txt + # datasette +asgiref==3.8.1 + # via + # -r requirements/requirements.txt + # datasette +canonicaljson==2.0.0 + # via + # -r requirements/requirements.txt + # digital-land +cchardet==2.1.7 + # via + # -r requirements/requirements.txt + # digital-land +certifi==2024.7.4 + # via + # -r requirements/requirements.txt + # httpcore + # httpx + # pyproj + # requests +charset-normalizer==3.3.2 + # via + # -r requirements/requirements.txt + # requests +click==8.1.7 + # via + # -r requirements/requirements.txt + # click-default-group + # dask + # datasette + # digital-land + # uvicorn +click-default-group==1.2.4 + # via + # -r requirements/requirements.txt + # datasette +cloudpickle==3.0.0 + # via + # -r requirements/requirements.txt + # dask +dask==2023.5.0 + # via + # -r requirements/requirements.txt + # digital-land +dataclasses-json==0.6.7 + # via + # -r requirements/requirements.txt + # digital-land +datasette==0.64.8 + # via + # -r requirements/requirements.txt + # digital-land +duckdb==1.0.0 + # via + # -r requirements/requirements.txt + # digital-land +esridump==1.13.0 + # via + # -r requirements/requirements.txt + # digital-land +et-xmlfile==1.1.0 + # via + # -r requirements/requirements.txt + # openpyxl +exceptiongroup==1.2.2 + # via + # -r requirements/requirements.txt + # anyio + # pytest +fsspec==2024.6.1 + # via + # -r requirements/requirements.txt + # dask +geojson==3.1.0 + # via + # -r requirements/requirements.txt + # digital-land +h11==0.14.0 + # via + # -r requirements/requirements.txt + # httpcore + # uvicorn +httpcore==1.0.5 + # via + # -r requirements/requirements.txt + # httpx +httpx==0.27.2 + # via + # -r requirements/requirements.txt + # datasette +hupper==1.12.1 + # via + # -r requirements/requirements.txt + # datasette +idna==3.8 + # via + # -r requirements/requirements.txt + # anyio + # httpx + # requests +importlib-metadata==8.4.0 + # via + # -r requirements/requirements.txt + # dask +iniconfig==2.0.0 + # via pytest +isodate==0.6.1 + # via + # -r requirements/requirements.txt + # rdflib +itsdangerous==2.2.0 + # via + # -r requirements/requirements.txt + # asgi-csrf + # datasette +janus==1.0.0 + # via + # -r requirements/requirements.txt + # datasette +jinja2==3.1.4 + # via + # -r requirements/requirements.txt + # datasette +json-stream==2.3.2 + # via + # -r requirements/requirements.txt + # digital-land +json-stream-rs-tokenizer==0.4.26 + # via + # -r requirements/requirements.txt + # json-stream +locket==1.0.0 + # via + # -r requirements/requirements.txt + # partd +markupsafe==2.1.5 + # via + # -r requirements/requirements.txt + # jinja2 +marshmallow==3.22.0 + # via + # -r requirements/requirements.txt + # dataclasses-json +mergedeep==1.3.4 + # via + # -r requirements/requirements.txt + # datasette +mypy-extensions==1.0.0 + # via + # -r requirements/requirements.txt + # typing-inspect +numpy==1.24.4 + # via + # -r requirements/requirements.txt + # digital-land + # pandas + # shapely +openpyxl==3.1.5 + # via + # -r requirements/requirements.txt + # digital-land +packaging==24.1 + # via + # -r requirements/requirements.txt + # dask + # marshmallow + # pytest +pandas==2.0.3 + # via + # -r requirements/requirements.txt + # digital-land +partd==1.4.1 + # via + # -r requirements/requirements.txt + # dask +pint==0.21.1 + # via + # -r requirements/requirements.txt + # datasette +pluggy==1.5.0 + # via + # -r requirements/requirements.txt + # datasette + # pytest +pydantic==2.8.2 + # via + # -r requirements/requirements.txt + # digital-land +pydantic-core==2.20.1 + # via + # -r requirements/requirements.txt + # pydantic +pyparsing==3.1.4 + # via + # -r requirements/requirements.txt + # rdflib +pyproj==3.5.0 + # via + # -r requirements/requirements.txt + # digital-land +pytest==8.3.2 + # via -r requirements/test-requirements.in +python-dateutil==2.9.0.post0 + # via + # -r requirements/requirements.txt + # pandas +python-multipart==0.0.9 + # via + # -r requirements/requirements.txt + # asgi-csrf +pytz==2024.1 + # via + # -r requirements/requirements.txt + # pandas +pyyaml==6.0.2 + # via + # -r requirements/requirements.txt + # dask + # datasette + # digital-land +rdflib==7.0.0 + # via + # -r requirements/requirements.txt + # sparqlwrapper +requests==2.32.3 + # via + # -r requirements/requirements.txt + # digital-land + # esridump +shapely==2.0.2 + # via + # -r requirements/requirements.txt + # digital-land +six==1.16.0 + # via + # -r requirements/requirements.txt + # esridump + # isodate + # python-dateutil +sniffio==1.3.1 + # via + # -r requirements/requirements.txt + # anyio + # httpx +sparqlwrapper==2.0.0 + # via + # -r requirements/requirements.txt + # digital-land +spatialite==0.0.3 + # via + # -r requirements/requirements.txt + # digital-land +tomli==2.0.1 + # via pytest +toolz==0.12.1 + # via + # -r requirements/requirements.txt + # dask + # partd +typing-extensions==4.12.2 + # via + # -r requirements/requirements.txt + # annotated-types + # anyio + # asgiref + # janus + # pydantic + # pydantic-core + # typing-inspect + # uvicorn +typing-inspect==0.9.0 + # via + # -r requirements/requirements.txt + # dataclasses-json +tzdata==2024.1 + # via + # -r requirements/requirements.txt + # pandas +urllib3==2.2.2 + # via + # -r requirements/requirements.txt + # requests +uvicorn==0.30.6 + # via + # -r requirements/requirements.txt + # datasette +validators==0.33.0 + # via + # -r requirements/requirements.txt + # digital-land +xlrd==1.2.0 + # via + # -r requirements/requirements.txt + # digital-land +zipp==3.20.1 + # via + # -r requirements/requirements.txt + # importlib-metadata + +# The following packages are considered to be unsafe in a requirements file: +# pip +# setuptools diff --git a/tests/acceptance/test_run.bats b/tests/acceptance/test_run.bats new file mode 100644 index 0000000..afa731f --- /dev/null +++ b/tests/acceptance/test_run.bats @@ -0,0 +1,28 @@ +#!/usr/bin/env bats + +# test_run_python_script.bats + +# Test if the Bash script runs the Python script and doesn't fail +@test "script runs" { + + function curl() { + echo "" + } + + function digital-land() { + echo "" + } + + export -f curl + export -f digital-land + + # change to the task directory + cd task + + # Run the Bash script and capture the output + run ./run.sh + + # Assert that the exit status is 0 (success) + [ "$status" -eq 0 ] +} +