[Groonga-commit] groonga/groonga at 50b7700 [master] regexp test: add a test for negative lookahead

Back to archive index

Yasuhiro Horimoto null+****@clear*****
Mon Sep 3 12:22:44 JST 2018


Yasuhiro Horimoto	2018-09-03 12:22:44 +0900 (Mon, 03 Sep 2018)

  Revision: 50b770090753e4c1d739fcf85ab198e0f5031941
  https://github.com/groonga/groonga/commit/50b770090753e4c1d739fcf85ab198e0f5031941

  Merged b69ab7e: Merge pull request #865 from komainu8/fix_negative_lookahead_result

  Message:
    regexp test: add a test for negative lookahead

  Added files:
    test/command/suite/select/filter/regexp/negative_lookahead.expected
    test/command/suite/select/filter/regexp/negative_lookahead.test

  Added: test/command/suite/select/filter/regexp/negative_lookahead.expected (+44 -0) 100644
===================================================================
--- /dev/null
+++ test/command/suite/select/filter/regexp/negative_lookahead.expected    2018-09-03 12:22:44 +0900 (7f21952b4)
@@ -0,0 +1,44 @@
+table_create Memos TABLE_HASH_KEY ShortText
+[[0,0.0,0.0],true]
+column_create Memos content COLUMN_SCALAR ShortText
+[[0,0.0,0.0],true]
+load --table Memos
+[
+{"_key": "1", "content": "Groonga"},
+{"_key": "2", "content": "mruby"}
+]
+[[0,0.0,0.0],2]
+select Memos --filter 'content @~ "^(?!.*Groonga).*$\"'
+[
+  [
+    0,
+    0.0,
+    0.0
+  ],
+  [
+    [
+      [
+        1
+      ],
+      [
+        [
+          "_id",
+          "UInt32"
+        ],
+        [
+          "_key",
+          "ShortText"
+        ],
+        [
+          "content",
+          "ShortText"
+        ]
+      ],
+      [
+        2,
+        "2",
+        "mruby"
+      ]
+    ]
+  ]
+]

  Added: test/command/suite/select/filter/regexp/negative_lookahead.test (+8 -0) 100644
===================================================================
--- /dev/null
+++ test/command/suite/select/filter/regexp/negative_lookahead.test    2018-09-03 12:22:44 +0900 (398099359)
@@ -0,0 +1,8 @@
+table_create Memos TABLE_HASH_KEY ShortText
+column_create Memos content COLUMN_SCALAR ShortText
+load --table Memos
+[
+{"_key": "1", "content": "Groonga"},
+{"_key": "2", "content": "mruby"}
+]
+select Memos --filter 'content @~ "^(?!.*Groonga).*$\"'
-------------- next part --------------
HTML����������������������������...
URL: https://lists.osdn.me/mailman/archives/groonga-commit/attachments/20180903/6ace4bcf/attachment-0001.htm 



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