[Groonga-commit] droonga/fluent-plugin-droonga at 5a7a9a8 [master] Add drntest cases for error of "add" command

アーカイブの一覧に戻る

YUKI Hiroshi null+****@clear*****
Thu Dec 26 13:28:42 JST 2013


YUKI Hiroshi	2013-12-26 13:28:42 +0900 (Thu, 26 Dec 2013)

  New Revision: 5a7a9a8e12015e954f3a4d31efa519376e1c4f8b
  https://github.com/droonga/fluent-plugin-droonga/commit/5a7a9a8e12015e954f3a4d31efa519376e1c4f8b

  Merged d5217b2: Merge branch 'master' of 192.168.1.21:~piro/groonga/fluent-plugin-droonga into HEAD

  Message:
    Add drntest cases for error of "add" command

  Added files:
    test/command/suite/add/missing-table.expected
    test/command/suite/add/missing-table.test
    test/command/suite/add/unknown-table.expected
    test/command/suite/add/unknown-table.test

  Added: test/command/suite/add/missing-table.expected (+13 -0) 100644
===================================================================
--- /dev/null
+++ test/command/suite/add/missing-table.expected    2013-12-26 13:28:42 +0900 (e7839bf)
@@ -0,0 +1,13 @@
+[
+  "droonga.message",
+  0,
+  {
+    "inReplyTo": null,
+    "statusCode": 400,
+    "type": "add.result",
+    "body": {
+      "name": "MissingTable",
+      "message": "\"table\" must be specified."
+    }
+  }
+]

  Added: test/command/suite/add/missing-table.test (+16 -0) 100644
===================================================================
--- /dev/null
+++ test/command/suite/add/missing-table.test    2013-12-26 13:28:42 +0900 (c63cd11)
@@ -0,0 +1,16 @@
+#@include fixture/user-table.jsons
+{
+  "type": "add",
+  "dataset": "Droonga",
+  "body": {
+    "key": "key",
+    "values": {
+      "name": "Alice",
+      "age": 20,
+      "email": [
+        "alice �� example.com",
+        "alice �� example.jp"
+      ]
+    }
+  }
+}

  Added: test/command/suite/add/unknown-table.expected (+13 -0) 100644
===================================================================
--- /dev/null
+++ test/command/suite/add/unknown-table.expected    2013-12-26 13:28:42 +0900 (2be22ea)
@@ -0,0 +1,13 @@
+[
+  "droonga.message",
+  0,
+  {
+    "inReplyTo": null,
+    "statusCode": 404,
+    "type": "add.result",
+    "body": {
+      "name": "UnknownTable",
+      "message": "The table \"Unknown\" does not exist in the dataset."
+    }
+  }
+]

  Added: test/command/suite/add/unknown-table.test (+17 -0) 100644
===================================================================
--- /dev/null
+++ test/command/suite/add/unknown-table.test    2013-12-26 13:28:42 +0900 (549f6c9)
@@ -0,0 +1,17 @@
+#@include fixture/user-table.jsons
+{
+  "type": "add",
+  "dataset": "Droonga",
+  "body": {
+    "table": "Unknown",
+    "key": "key",
+    "values": {
+      "name": "Alice",
+      "age": 20,
+      "email": [
+        "alice �� example.com",
+        "alice �� example.jp"
+      ]
+    }
+  }
+}
-------------- next part --------------
HTML����������������������������...
ダウンロード 



More information about the Groonga-commit mailing list
アーカイブの一覧に戻る