From 05e94adc1a717e85ba5b775468c3c9e2c8a26034 Mon Sep 17 00:00:00 2001 From: Adam Dickmeiss Date: Wed, 29 May 2013 10:43:24 +0200 Subject: [PATCH] CCL: tests for configurable mask/truncation --- test/test_ccl.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/test/test_ccl.c b/test/test_ccl.c index 9e2b927..d189f00 100644 --- a/test/test_ccl.c +++ b/test/test_ccl.c @@ -429,6 +429,9 @@ void tst2(void) ccl_qual_fitem(bibset, "u=4 s=pw t=l,r", "ti"); ccl_qual_fitem(bibset, "1=1016 s=al,pw t=z", "term"); + YAZ_CHECK(tst_ccl_query(bibset, "a?#", + "@attr 5=104 @attr 4=2 @attr 1=1016 a?# ")); + YAZ_CHECK(tst_ccl_query(bibset, "a*", "@attr 4=2 @attr 1=1016 a* ")); @@ -442,6 +445,16 @@ void tst2(void) YAZ_CHECK(tst_ccl_query(bibset, "a?", "@attr 5=104 @attr 4=2 @attr 1=1016 a\\\\? ")); + ccl_qual_fitem(bibset, "?", "@mask"); + YAZ_CHECK(tst_ccl_query(bibset, "a?", + "@attr 5=104 @attr 4=2 @attr 1=1016 a# ")); + + + ccl_qual_fitem(bibset, "", "@mask"); + ccl_qual_fitem(bibset, "", "@truncation"); + YAZ_CHECK(tst_ccl_query(bibset, "a?#", + "@attr 5=104 @attr 4=2 @attr 1=1016 a\\\\?\\\\# ")); + ccl_qual_fitem(bibset, "og", "@and"); ccl_qual_fitem(bibset, "eller", "@or"); ccl_qual_fitem(bibset, "ikke", "@not"); -- 1.7.10.4