You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nlpcraft.apache.org by ar...@apache.org on 2020/09/19 08:10:36 UTC
[incubator-nlpcraft] branch master updated: Update NCRestSpec.scala
This is an automated email from the ASF dual-hosted git repository.
aradzinski pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nlpcraft.git
The following commit(s) were added to refs/heads/master by this push:
new ddf2af2 Update NCRestSpec.scala
ddf2af2 is described below
commit ddf2af261f0d7a43c11286b56e790640466e75c2
Author: Aaron Radzinski <ar...@datalingvo.com>
AuthorDate: Sat Sep 19 01:10:26 2020 -0700
Update NCRestSpec.scala
---
.../org/apache/nlpcraft/server/rest/NCRestSpec.scala | 18 +++++++++++-------
1 file changed, 11 insertions(+), 7 deletions(-)
diff --git a/nlpcraft/src/test/scala/org/apache/nlpcraft/server/rest/NCRestSpec.scala b/nlpcraft/src/test/scala/org/apache/nlpcraft/server/rest/NCRestSpec.scala
index 908277e..77abb9d 100644
--- a/nlpcraft/src/test/scala/org/apache/nlpcraft/server/rest/NCRestSpec.scala
+++ b/nlpcraft/src/test/scala/org/apache/nlpcraft/server/rest/NCRestSpec.scala
@@ -241,13 +241,17 @@ private[rest] class NCRestSpec extends NCTestContext {
post.releaseConnection()
println(s"Checked POST with expected error [httpErrCode=$httpErrCode, errorCode=$errCode]")
- println(GSON.toJson(
- Map(
- "url" → url,
- "params" → new java.util.HashMap[String, Any](ps.toMap.asJava),
- "response" → Map("httpCode" → err.httpCode, "json" → GSON.fromJson(err.js, TYPE_RESP)).asJava
- ).asJava
- ))
+ println(
+ U.colorJson(
+ GSON.toJson(
+ Map(
+ "url" → url,
+ "params" → new java.util.HashMap[String, Any](ps.toMap.asJava),
+ "response" → Map("httpCode" → err.httpCode, "json" → GSON.fromJson(err.js, TYPE_RESP)).asJava
+ ).asJava
+ )
+ )
+ )
println()
assertEquals(httpErrCode, err.httpCode)