You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openwhisk.apache.org by cs...@apache.org on 2017/09/18 14:55:40 UTC
[incubator-openwhisk-cli] 12/16: Remove redundant test suite. Also
remove some spurious log messages. (#2693)
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 04908d5a2d24e30aede4394b71a41de3c5bc9ecf
Author: rodric rabbah <ro...@gmail.com>
AuthorDate: Thu Sep 7 11:10:28 2017 -0400
Remove redundant test suite. Also remove some spurious log messages. (#2693)
---
tests/src/test/scala/system/basic/WskConsoleTests.scala | 1 -
tests/src/test/scala/system/basic/WskSequenceTests.scala | 14 ++++++--------
2 files changed, 6 insertions(+), 9 deletions(-)
diff --git a/tests/src/test/scala/system/basic/WskConsoleTests.scala b/tests/src/test/scala/system/basic/WskConsoleTests.scala
index c2191fa..7abbeeb 100644
--- a/tests/src/test/scala/system/basic/WskConsoleTests.scala
+++ b/tests/src/test/scala/system/basic/WskConsoleTests.scala
@@ -66,7 +66,6 @@ class WskConsoleTests extends TestHelpers with WskTestHelpers {
val run = wsk.action.invoke(fullActionName, Map("payload" -> payload.toJson))
withActivation(wsk.activation, run, totalWait = duration.get) { activation =>
val console = wsk.activation.console(10 seconds, since = duration)
- println(console.stdout)
console.stdout should include(payload)
}
}
diff --git a/tests/src/test/scala/system/basic/WskSequenceTests.scala b/tests/src/test/scala/system/basic/WskSequenceTests.scala
index bd5cdc0..1b90b6d 100644
--- a/tests/src/test/scala/system/basic/WskSequenceTests.scala
+++ b/tests/src/test/scala/system/basic/WskSequenceTests.scala
@@ -72,7 +72,6 @@ class WskSequenceTests extends TestHelpers with ScalatestRouteTest with WskTestH
}
}
- println(s"Sequence $actions")
assetHelper.withCleaner(wsk.action, name) {
val sequence = actions.mkString(",")
(action, _) =>
@@ -93,7 +92,6 @@ class WskSequenceTests extends TestHelpers with ScalatestRouteTest with WskTestH
// update action sequence and run it with normal payload
val newSequence = Seq("split", "sort").mkString(",")
- println(s"Update sequence to $newSequence")
wsk.action.create(
name,
Some(newSequence),
@@ -108,7 +106,6 @@ class WskSequenceTests extends TestHelpers with ScalatestRouteTest with WskTestH
result.fields.get("lines") shouldBe Some(args.sortWith(_.compareTo(_) < 0).toArray.toJson)
}
- println("Run sequence with error in payload")
// 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
@@ -197,7 +194,7 @@ class WskSequenceTests extends TestHelpers with ScalatestRouteTest with WskTestH
val args = Array("what time is it?", now)
val argsJson = args.mkString("\n").toJson
val run = wsk.action.invoke(sName, Map("payload" -> argsJson))
- println(s"RUN: ${run.stdout}")
+
withActivation(wsk.activation, run, totalWait = 2 * allowedActionDuration) { activation =>
checkSequenceLogsAndAnnotations(activation, 3) // 3 activations in this sequence
val result = activation.response.result.get
@@ -530,10 +527,11 @@ class WskSequenceTests extends TestHelpers with ScalatestRouteTest with WskTestH
val componentId = activation.logs.get(atomicActionIdx)
val getComponentActivation = wsk.activation.get(Some(componentId))
withActivation(wsk.activation, getComponentActivation, totalWait = allowedActionDuration) { componentActivation =>
- println(componentActivation)
- componentActivation.logs shouldBe defined
- val logs = componentActivation.logs.get.mkString(" ")
- regex.findFirstIn(logs) shouldBe defined
+ withClue(componentActivation) {
+ componentActivation.logs shouldBe defined
+ val logs = componentActivation.logs.get.mkString(" ")
+ regex.findFirstIn(logs) shouldBe defined
+ }
}
}
}
--
To stop receiving notification emails like this one, please contact
"commits@openwhisk.apache.org" <co...@openwhisk.apache.org>.