[Groonga-commit] groonga/groonga at 52cf0f8 [master] Add tests for vector reference output

Back to archive index

Kouhei Sutou null+****@clear*****
Wed Jun 12 12:38:05 JST 2013


Kouhei Sutou	2013-06-12 12:38:05 +0900 (Wed, 12 Jun 2013)

  New Revision: 52cf0f89b231aa19ee280e97ae62ddb96142f84d
  https://github.com/groonga/groonga/commit/52cf0f89b231aa19ee280e97ae62ddb96142f84d

  Message:
    Add tests for vector reference output

  Added files:
    test/command/suite/select/output_columns/vector/reference/no_key/json.expected
    test/command/suite/select/output_columns/vector/reference/no_key/json.test
    test/command/suite/select/output_columns/vector/reference/no_key/xml.expected
    test/command/suite/select/output_columns/vector/reference/no_key/xml.test

  Added: test/command/suite/select/output_columns/vector/reference/no_key/json.expected (+43 -0) 100644
===================================================================
--- /dev/null
+++ test/command/suite/select/output_columns/vector/reference/no_key/json.expected    2013-06-12 12:38:05 +0900 (7e35f2f)
@@ -0,0 +1,43 @@
+table_create Users TABLE_HASH_KEY ShortText
+[[0,0.0,0.0],true]
+table_create Bookmarks TABLE_HASH_KEY ShortText
+[[0,0.0,0.0],true]
+column_create Bookmarks users COLUMN_VECTOR Users
+[[0,0.0,0.0],true]
+load --table Bookmarks
+[
+{"_key": "http://groonga.org/", "users": ["mori", "s-yata"]}
+]
+[[0,0.0,0.0],1]
+select Bookmarks --output_columns _key,users
+[
+  [
+    0,
+    0.0,
+    0.0
+  ],
+  [
+    [
+      [
+        1
+      ],
+      [
+        [
+          "_key",
+          "ShortText"
+        ],
+        [
+          "users",
+          "Users"
+        ]
+      ],
+      [
+        "http://groonga.org/",
+        [
+          "mori",
+          "s-yata"
+        ]
+      ]
+    ]
+  ]
+]

  Added: test/command/suite/select/output_columns/vector/reference/no_key/json.test (+11 -0) 100644
===================================================================
--- /dev/null
+++ test/command/suite/select/output_columns/vector/reference/no_key/json.test    2013-06-12 12:38:05 +0900 (9e67388)
@@ -0,0 +1,11 @@
+table_create Users TABLE_HASH_KEY ShortText
+
+table_create Bookmarks TABLE_HASH_KEY ShortText
+column_create Bookmarks users COLUMN_VECTOR Users
+
+load --table Bookmarks
+[
+{"_key": "http://groonga.org/", "users": ["mori", "s-yata"]}
+]
+
+select Bookmarks --output_columns _key,users

  Added: test/command/suite/select/output_columns/vector/reference/no_key/xml.expected (+27 -0) 100644
===================================================================
--- /dev/null
+++ test/command/suite/select/output_columns/vector/reference/no_key/xml.expected    2013-06-12 12:38:05 +0900 (0827499)
@@ -0,0 +1,27 @@
+table_create Users TABLE_HASH_KEY ShortText
+[[0,0.0,0.0],true]
+table_create Bookmarks TABLE_HASH_KEY ShortText
+[[0,0.0,0.0],true]
+column_create Bookmarks users COLUMN_VECTOR Users
+[[0,0.0,0.0],true]
+load --table Bookmarks
+[
+{"_key": "http://groonga.org/", "users": ["mori", "s-yata"]}
+]
+[[0,0.0,0.0],1]
+select Bookmarks --output_columns _key,users --output_type xml
+<?xml version="1.0" encoding="utf-8"?>
+<SEGMENTS>
+<SEGMENT>
+<RESULTPAGE>
+<RESULTSET OFFSET="0" LIMIT="1" NHITS="1">
+<HIT NO="1">
+<FIELD NAME="_key">http://groonga.org/</FIELD>
+<FIELD NAME="users">mori, s-yata</FIELD>
+</HIT>
+</RESULTSET>
+</RESULTPAGE>
+</SEGMENT>
+</SEGMENTS>
+
+

  Added: test/command/suite/select/output_columns/vector/reference/no_key/xml.test (+11 -0) 100644
===================================================================
--- /dev/null
+++ test/command/suite/select/output_columns/vector/reference/no_key/xml.test    2013-06-12 12:38:05 +0900 (ed66308)
@@ -0,0 +1,11 @@
+table_create Users TABLE_HASH_KEY ShortText
+
+table_create Bookmarks TABLE_HASH_KEY ShortText
+column_create Bookmarks users COLUMN_VECTOR Users
+
+load --table Bookmarks
+[
+{"_key": "http://groonga.org/", "users": ["mori", "s-yata"]}
+]
+
+select Bookmarks --output_columns _key,users --output_type xml
-------------- next part --------------
HTML����������������������������...
Download 



More information about the Groonga-commit mailing list
Back to archive index