[glib] Add regex test cases



commit b67d9cb7eef036b76955a75e6e9cd6b8ae1fb8e4
Author: Matthias Clasen <mclasen redhat com>
Date:   Fri Jan 7 12:07:19 2011 -0500

    Add regex test cases
    
    These come from https://bugzilla.gnome.org/show_bug.cgi?id=638894

 glib/tests/regex.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/glib/tests/regex.c b/glib/tests/regex.c
index bd46a5e..6e015e9 100644
--- a/glib/tests/regex.c
+++ b/glib/tests/regex.c
@@ -2357,6 +2357,8 @@ main (int argc, char *argv[])
   TEST_SPLIT_SIMPLE3(",\\s*", "a, b, c", "a", "b", "c");
   TEST_SPLIT_SIMPLE3("(,)\\s*", "a,b", "a", ",", "b");
   TEST_SPLIT_SIMPLE3("(,)\\s*", "a, b", "a", ",", "b");
+  TEST_SPLIT_SIMPLE2("\\s", "ab c", "ab", "c");
+  TEST_SPLIT_SIMPLE3("\\s*", "ab c", "a", "b", "c");
   /* Not matched sub-strings. */
   TEST_SPLIT_SIMPLE2("a|(b)", "xay", "x", "y");
   TEST_SPLIT_SIMPLE3("a|(b)", "xby", "x", "b", "y");



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]