2 * Copyright (C) 1995-2005, Index Data ApS
3 * See the file LICENSE for details.
5 * $Id: tstmatchstr.c,v 1.5 2006-01-29 21:59:13 adam Exp $
11 #include <yaz/yaz-iconv.h>
14 int main (int argc, char **argv)
16 YAZ_CHECK_INIT(argc, argv);
18 YAZ_CHECK(yaz_matchstr("x", "x") == 0);
19 YAZ_CHECK(yaz_matchstr("x", "X") == 0);
20 YAZ_CHECK(yaz_matchstr("a", "b") > 0);
21 YAZ_CHECK(yaz_matchstr("b", "a") > 0);
22 YAZ_CHECK(yaz_matchstr("aa","a") > 0);
23 YAZ_CHECK(yaz_matchstr("a-", "a") > 0);
24 YAZ_CHECK(yaz_matchstr("A-b", "ab") == 0);
25 YAZ_CHECK(yaz_matchstr("A--b", "ab") > 0);
26 YAZ_CHECK(yaz_matchstr("A--b", "a-b") > 0);
27 YAZ_CHECK(yaz_matchstr("A--b", "a--b") == 0);
28 YAZ_CHECK(yaz_matchstr("a123", "a?") == 0);
29 YAZ_CHECK(yaz_matchstr("a123", "a1.3") == 0);
30 YAZ_CHECK(yaz_matchstr("a123", "..?") == 0);
31 YAZ_CHECK(yaz_matchstr("a123", "a1.") > 0);
32 YAZ_CHECK(yaz_matchstr("a123", "a...") == 0);
40 * indent-tabs-mode: nil
42 * vim: shiftwidth=4 tabstop=8 expandtab