This is an automated email from the ASF dual-hosted git repository. csantanapr pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/incubator-openwhisk-cli.git
commit 18a9b0ba112776cce8aa86135fb213bc6ba41b22 Author: Ioana Baldini <io...@us.ibm.com> AuthorDate: Sat Mar 18 10:22:29 2017 -0400 Treat error field differently if present in the initial payload to a sequence. Update test accordingly. (#1831) --- .../test/scala/system/basic/WskSequenceTests.scala | 20 ++++++++------------ 1 file changed, 8 insertions(+), 12 deletions(-) diff --git a/tests/src/test/scala/system/basic/WskSequenceTests.scala b/tests/src/test/scala/system/basic/WskSequenceTests.scala index 4a8b037..e0dfdef 100644 --- a/tests/src/test/scala/system/basic/WskSequenceTests.scala +++ b/tests/src/test/scala/system/basic/WskSequenceTests.scala @@ -104,21 +104,17 @@ class WskSequenceTests } println("Run sequence with error in payload") - // run sequence with error in the payload; nothing should run - val payload = Map("error" -> JsString("irrelevant error string")) + // run sequence with error in the payload + // sequence should run with no problems, error should be ignored in this test case + // result of sequence should be identical to previous invocation above + val payload = Map("error" -> JsString("irrelevant error string"), "payload" -> args.mkString("\n").toJson) val thirdrun = wsk.action.invoke(name, payload) - withActivation(wsk.activation, thirdrun, totalWait = allowedActionDuration) { + withActivation(wsk.activation, thirdrun, totalWait = 2 *allowedActionDuration) { activation => - activation.logs shouldBe defined - // no activations should have run - activation.logs.get.size shouldBe (0) - activation.response.success shouldBe (false) - // the status should be error - activation.response.status shouldBe ("application error") + checkSequenceLogsAndAnnotations(activation, 2) // 2 activations in this sequence val result = activation.response.result.get - // the result of the activation should be the payload - result shouldBe (JsObject(payload)) - + result.fields.get("length") shouldBe Some(2.toJson) + result.fields.get("lines") shouldBe Some(args.sortWith(_.compareTo(_) < 0).toArray.toJson) } } -- To stop receiving notification emails like this one, please contact "commits@openwhisk.apache.org" <commits@openwhisk.apache.org>.