dubeejw commented on a change in pull request #2741: Display content-type in
__ow_headers for web actions
URL:
https://github.com/apache/incubator-openwhisk/pull/2741#discussion_r139491456
##########
File path:
tests/src/test/scala/whisk/core/controller/test/WebActionsApiTests.scala
##########
@@ -1430,17 +1439,19 @@ trait WebActionsApiTests extends ControllerTestCommon
with BeforeAndAfterEach wi
invocationsAllowed = 1
val queryString = "key1=value1&key2=value2"
- Post(s"$testRoutePath/$systemId/proxy/raw_export_c.json?$queryString",
str) ~> addHeader(
- "Content-type",
- MediaTypes.`application/json`.value) ~> Route.seal(routes(creds)) ~>
check {
+ Post(
+ s"$testRoutePath/$systemId/proxy/raw_export_c.json?$queryString",
+ HttpEntity(ContentTypes.`application/json`, str)) ~>
Route.seal(routes(creds)) ~> check {
status should be(OK)
val response = responseAs[JsObject]
response shouldBe JsObject(
"pkg" -> s"$systemId/proxy".toJson,
"action" -> "raw_export_c".toJson,
"content" -> metaPayload(
Post.method.name.toLowerCase,
- Map(webApiDirectives.body -> str.toJson, webApiDirectives.query ->
queryString.toJson).toJson.asJsObject,
Review comment:
Yeah, test was wrong.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services