Skip to content
Snippets Groups Projects
Commit d42ee545 authored by James Dubee's avatar James Dubee Committed by rodric rabbah
Browse files

Properly Handle Errors Received from Blocking Invocations (#1820)

- Display proper error message during a blocking invocation when result flag is being used
parent 5c6a90be
No related branches found
No related tags found
No related merge requests found
......@@ -357,6 +357,17 @@ class WskBasicTests
}
}
it should "create and invoke a blocking action resulting in an application error response" in withAssetCleaner(wskprops) {
(wp, assetHelper) =>
val name = "applicationError3"
assetHelper.withCleaner(wsk.action, name) {
(action, _) => action.create(name, Some(TestUtils.getTestActionFilename("applicationError3.js")))
}
wsk.action.invoke(name, blocking = true, result = true, expectedExitCode = 246)
.stderr.parseJson.asJsObject shouldBe JsObject("error" -> JsBoolean(true))
}
it should "create and invoke a blocking action resulting in an failed promise" in withAssetCleaner(wskprops) {
(wp, assetHelper) =>
val name = "errorResponseObject"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment