[Groonga-commit] groonga/groonga [master] add a test for deleted record is selected. #617

Back to archive index

null+****@clear***** null+****@clear*****
2010年 10月 19日 (火) 09:09:13 JST


Kouhei Sutou	2010-10-19 00:09:13 +0000 (Tue, 19 Oct 2010)

  New Revision: 2ac1af89c4e9cc3d6c02e0e39a35dad26a87fb75

  Log:
    add a test for deleted record is selected. #617

  Modified files:
    test/unit/core/test-command-delete.c

  Modified: test/unit/core/test-command-delete.c (+22 -0)
===================================================================
--- test/unit/core/test-command-delete.c    2010-10-18 16:23:09 +0000 (b98f70e)
+++ test/unit/core/test-command-delete.c    2010-10-19 00:09:13 +0000 (9c733ad)
@@ -27,6 +27,7 @@ void test_by_id(void);
 void test_by_key(void);
 void test_referenced_record(void);
 void test_uint64(void);
+void test_last_token(void);
 
 static gchar *tmp_directory;
 
@@ -166,3 +167,24 @@ test_uint64(void)
                           send_command("select Students "
                                        "--output_columns _key"));
 }
+
+void
+test_last_token(void)
+{
+  cut_assert_equal_string("[[[2],"
+                            "[[\"_key\",\"ShortText\"]],"
+                            "[\"mori\"],"
+                            "[\"tapo\"]]]",
+                          send_command("select Users "
+                                       "--match_columns _key "
+                                       "--query o "
+                                       "--output_columns _key"));
+  assert_send_command("delete Users tapo");
+  cut_assert_equal_string("[[[1],"
+                            "[[\"_key\",\"ShortText\"]],"
+                            "[\"mori\"]]]",
+                          send_command("select Users "
+                                       "--match_columns _key "
+                                       "--query o "
+                                       "--output_columns _key"));
+}




Groonga-commit メーリングリストの案内
Back to archive index