Skip to content

Commit

Permalink
Fixing typo and adding missing format in test
Browse files Browse the repository at this point in the history
  • Loading branch information
Nazim-crim committed Nov 6, 2024
1 parent e6143b5 commit 6bfb158
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 8 deletions.
2 changes: 1 addition & 1 deletion tests/functional/test_cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -446,7 +446,7 @@ def test_describe(self):
for out_fmt in output_formats:
out_fmt.pop("$schema", None)
out_fmt.pop("$id", None)
assert output_formats == [{"default": True, "mediaType": ContentType.TEXT_PLAIN}]
assert output_formats == [{"default": True, "mediaType": ContentType.TEXT_PLAIN}, {'mediaType': 'application/pdf'}]
assert "undefined" not in result.message, "CLI should not have confused process description as response detail."
assert result.body["description"] == (
"Dummy process that simply echo's back the input message for testing purposes."
Expand Down
3 changes: 2 additions & 1 deletion tests/functional/test_wps_provider.py
Original file line number Diff line number Diff line change
Expand Up @@ -150,9 +150,10 @@ def test_register_describe_execute_ncdump(self, mock_responses):
assert "outputs" in body and len(body["outputs"]) == 1
assert "output" in body["outputs"]
assert "formats" in body["outputs"]["output"]
assert len(body["outputs"]["output"]["formats"]) == 1
assert len(body["outputs"]["output"]["formats"]) == 2
assert body["outputs"]["output"]["formats"][0]["default"] is True
assert body["outputs"]["output"]["formats"][0]["mediaType"] == ContentType.TEXT_PLAIN
assert body["outputs"]["output"]["formats"][1]["mediaType"] == ContentType.APP_PDF
assert "literalDataDomains" not in body["outputs"]["output"]

assert body["processDescriptionURL"] == proc_desc_url
Expand Down
12 changes: 6 additions & 6 deletions tests/wps_restapi/test_processes.py
Original file line number Diff line number Diff line change
Expand Up @@ -998,7 +998,7 @@ def deploy_process_CWL_direct(self,
"contentMediaType": "text/plain"
},
{
"typse": "string",
"type": "string",
"format": "binary",
"contentMediaType": "application/pdf",
"contentEncoding": "base64"
Expand Down Expand Up @@ -1103,7 +1103,7 @@ def test_deploy_process_CWL_DockerRequirement_href(self):
"contentMediaType": "text/plain"
},
{
"typse": "string",
"type": "string",
"format": "binary",
"contentMediaType": "application/pdf",
"contentEncoding": "base64"
Expand Down Expand Up @@ -1156,7 +1156,7 @@ def test_deploy_process_CWL_DockerRequirement_owsContext(self):
"contentMediaType": "text/plain"
},
{
"typse": "string",
"type": "string",
"format": "binary",
"contentMediaType": "application/pdf",
"contentEncoding": "base64"
Expand Down Expand Up @@ -1207,7 +1207,7 @@ def test_deploy_process_CWL_DockerRequirement_executionUnit(self):
"contentMediaType": "text/plain"
},
{
"typse": "string",
"type": "string",
"format": "binary",
"contentMediaType": "application/pdf",
"contentEncoding": "base64"
Expand Down Expand Up @@ -1258,7 +1258,7 @@ def test_deploy_process_CWL_DockerRequirement_executionUnit_DirectUnit(self):
"contentMediaType": "text/plain"
},
{
"typse": "string",
"type": "string",
"format": "binary",
"contentMediaType": "application/pdf",
"contentEncoding": "base64"
Expand Down Expand Up @@ -1309,7 +1309,7 @@ def test_deploy_process_CWL_DockerRequirement_executionUnit_UnitWithMediaType(se
"contentMediaType": "text/plain"
},
{
"typse": "string",
"type": "string",
"format": "binary",
"contentMediaType": "application/pdf",
"contentEncoding": "base64"
Expand Down

0 comments on commit 6bfb158

Please sign in to comment.