Skip to content

Commit a365101

Browse files
tomkralidiskalxas
authored andcommitted
update OAProc process list filtering
1 parent de144a5 commit a365101

File tree

6 files changed

+12
-12
lines changed

6 files changed

+12
-12
lines changed

owslib/ogcapi/coverages.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,11 @@ def __init__(self, url: str, json_: str = None, timeout: int = 30,
2424
__doc__ = Collections.__doc__ # noqa
2525
super().__init__(url, json_, timeout, headers, auth)
2626

27-
def coverages(self) -> dict:
27+
def coverages(self) -> list:
2828
"""
2929
implements /collections filtered on coverages
3030
31-
@returns: `dict` of filtered collections object
31+
@returns: `list` of filtered collections object
3232
"""
3333

3434
coverages_ = []

owslib/ogcapi/features.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,11 @@ def __init__(self, url: str, json_: str = None, timeout: int = 30,
2424
__doc__ = Collections.__doc__ # noqa
2525
super().__init__(url, json_, timeout, headers, auth)
2626

27-
def feature_collections(self) -> dict:
27+
def feature_collections(self) -> list:
2828
"""
2929
implements /collections filtered on features
3030
31-
@returns: `dict` of filtered collections object
31+
@returns: `list` of filtered collections object
3232
"""
3333

3434
features_ = []

owslib/ogcapi/maps.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,11 @@ def __init__(self, url: str, json_: str = None, timeout: int = 30,
2424
__doc__ = Collections.__doc__ # noqa
2525
super().__init__(url, json_, timeout, headers, auth)
2626

27-
def maps(self) -> dict:
27+
def maps(self) -> list:
2828
"""
2929
implements /collections filtered on maps
3030
31-
@returns: `dict` of filtered collections object
31+
@returns: `list` of filtered collections object
3232
"""
3333

3434
maps_ = []

owslib/ogcapi/processes.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -22,15 +22,15 @@ def __init__(self, url: str, json_: str = None, timeout: int = 30,
2222
__doc__ = Collections.__doc__ # noqa
2323
super().__init__(url, json_, timeout, headers, auth)
2424

25-
def processes(self) -> dict:
25+
def processes(self) -> list:
2626
"""
2727
implements /processes
2828
29-
@returns: `dict` of available processes
29+
@returns: `list` of available processes
3030
"""
3131

3232
path = 'processes'
33-
return self._request(path=path)
33+
return self._request(path=path)['processes']
3434

3535
def process(self, process_id: str) -> dict:
3636
"""

owslib/ogcapi/records.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,11 @@ def __init__(self, url: str, json_: str = None, timeout: int = 30,
2222
__doc__ = Features.__doc__ # noqa
2323
super().__init__(url, json_, timeout, headers, auth)
2424

25-
def records(self) -> dict:
25+
def records(self) -> list:
2626
"""
2727
implements /collections filtered on records
2828
29-
@returns: `dict` of filtered collections object
29+
@returns: `list` of filtered collections object
3030
"""
3131

3232
records_ = []

tests/test_ogcapi_processes_pygeoapi.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ def test_ogcapi_processes_pygeoapi():
2929
assert len(collections) > 0
3030

3131
processes = p.processes()
32-
assert len(processes) == 1
32+
assert len(processes) == 3
3333

3434
hello_world = p.process('hello-world')
3535
assert hello_world['id'] == 'hello-world'

0 commit comments

Comments
 (0)