rabbah commented on a change in pull request #2444: Display CORS Headers for
Non-Options Requests
URL:
https://github.com/apache/incubator-openwhisk/pull/2444#discussion_r124850078
##########
File path: tests/src/test/scala/whisk/core/cli/test/WskWebActionsTests.scala
##########
@@ -230,6 +230,25 @@ trait WskWebActionsTests
response.header("Access-Control-Allow-Headers") shouldBe "Headers
set from Web Action"
}
+ it should "ensure that CORS header is preserved for non-custom options" in
withAssetCleaner(wskprops) {
+ (wp, assetHelper) =>
+ val name = "webaction"
+ val file =
Some(TestUtils.getTestActionFilename("corsHeaderMod.js"))
+
+ assetHelper.withCleaner(wsk.action, name) {
+ (action, _) =>
+ action.create(name, file, web = Some("true"))
+ }
+
+ val host = getServiceURL()
+ val url = host +
s"$testRoutePath/$namespace/default/webaction.http"
Review comment:
want to test this for non `.http` extension also.
----------------------------------------------------------------
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