Skip to content

Commit

Permalink
test adjustments
Browse files Browse the repository at this point in the history
  • Loading branch information
Zeitsperre committed Feb 4, 2021
1 parent 0923678 commit 61d88ca
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 30 deletions.
2 changes: 1 addition & 1 deletion tests/test_wps_chomsky.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

def test_wps_chomsky():
client = client_for(Service(processes=[Chomsky()]))
datainputs = f"times={10}"
datainputs = "times=10"
resp = client.get(
service='WPS', request='Execute', version='1.0.0',
identifier='chomsky',
Expand Down
29 changes: 1 addition & 28 deletions tests/test_wps_geo.py
Original file line number Diff line number Diff line change
@@ -1,34 +1,7 @@
import pytest

from pywps import Service
from pywps.tests import assert_response_success
from emu.processes.wps_geodata import GeoData
from emu.processes.wps_geospatial import GeoSpatial
from .common import client_for, CFG_FILE, resource_file


def test_wps_geospatial():

client = client_for(Service(processes=[GeoSpatial()], cfgfiles=CFG_FILE))
datainputs = f"vector=@xlink:href=file://{resource_file('Olympus_Mons.geojson')};" \
f"raster=@xlink:href=file://{resource_file('Olympus.tif')}"

resp = client.get(
service='wps', request='execute', version='1.0.0',
identifier='geospatial', datainputs=datainputs)
assert_response_success(resp)


def test_wps_geospatial_novector_fails():

client = client_for(Service(processes=[GeoSpatial()], cfgfiles=CFG_FILE))
datainputs = f"raster=@xlink:href=file://{resource_file('Olympus.tif')}"

with pytest.raises(AssertionError):
resp = client.get(
service='wps', request='execute', version='1.0.0',
identifier='geospatial', datainputs=datainputs)
assert_response_success(resp)
from .common import client_for, CFG_FILE


def test_wps_geodata():
Expand Down
2 changes: 1 addition & 1 deletion tests/test_wps_multiple_outputs.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
@pytest.fixture
def resp():
client = client_for(Service(processes=[MultipleOutputs()], cfgfiles=CFG_FILE))
datainputs = f'count={5}'
datainputs = 'count=5'
response = client.get(
service="WPS", request="Execute", version="1.0.0", identifier="multiple_outputs",
datainputs=datainputs)
Expand Down

0 comments on commit 61d88ca

Please sign in to comment.