ningyougang commented on code in PR #5290:
URL: https://github.com/apache/openwhisk/pull/5290#discussion_r926335947


##########
tests/src/test/scala/system/basic/WskActionTests.scala:
##########
@@ -392,4 +392,18 @@ class WskActionTests extends TestHelpers with 
WskTestHelpers with JsHelpers with
       }
   }
 
+  it should "invoke an action with a array result" in 
withAssetCleaner(wskprops) { (wp, assetHelper) =>
+    val name = "helloArray"
+    assetHelper.withCleaner(wsk.action, name) { (action, _) =>
+      action.create(name, 
Some(TestUtils.getTestActionFilename("helloArray.js")))
+    }
+
+    val run = wsk.action.invoke(name)
+    withActivation(wsk.activation, run) { activation =>
+      activation.response.status shouldBe "success"
+      activation.response.result shouldBe Some(
+        JsArray(JsObject("key1" -> JsString("value1")), JsObject("key2" -> 
JsString("value2"))))
+    }
+  }

Review Comment:
   Because `nodejs runtime` suports array result by default, add a system test 
case for return array result for it to test controller/invoker whether works 
well



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to