X-Git-Url: http://git.indexdata.com/?p=yaz-moved-to-github.git;a=blobdiff_plain;f=test%2Ftstccl.c;h=dada1e04a6a058f4a3a9c168e8af12d6d251b736;hp=f1ce44025fc08fa249f1c4f7c1dfc209987de37b;hb=4adfba7e638623bfdca78c454d274174f7d1e01e;hpb=3f02a85787de9b5340914aec0738f9eb46e89d79;ds=sidebyside
diff --git a/test/tstccl.c b/test/tstccl.c
index f1ce440..dada1e0 100644
--- a/test/tstccl.c
+++ b/test/tstccl.c
@@ -74,6 +74,8 @@ void tst1(int pass)
ccl_qual_fitem(bibset, "1=/my/title", "dc.title");
ccl_qual_fitem(bibset, "r=r", "date");
ccl_qual_fitem(bibset, "r=o", "x");
+ ccl_qual_fitem(bibset, "dc.title", "title");
+ ccl_qual_fitem(bibset, "term dc.title", "comb");
break;
case 1:
strcpy(tstline, "ti u=4 s=pw t=l,r");
@@ -90,6 +92,12 @@ void tst1(int pass)
strcpy(tstline, "x r=o # ordered relation");
ccl_qual_line(bibset, tstline);
+
+ strcpy(tstline, "title dc.title # alias");
+ ccl_qual_line(bibset, tstline);
+
+ strcpy(tstline, "comb term dc.title # combination");
+ ccl_qual_line(bibset, tstline);
break;
case 2:
ccl_qual_buf(bibset, "ti u=4 s=pw t=l,r\n"
@@ -98,6 +106,8 @@ void tst1(int pass)
"dc.title 1=/my/title\n"
"date r=r\n"
"x r=o\n"
+ "title dc.title\n"
+ "comb term dc.title\n"
);
break;
case 3:
@@ -128,6 +138,13 @@ void tst1(int pass)
" \n"
" \n"
" \n"
+ " \n"
+ " \n"
+ " \n"
+ " \n"
+ " \n"
+ " \n"
+ " \n"
"\n";
doc = xmlParseMemory(xml_str, strlen(xml_str));
@@ -217,6 +234,13 @@ void tst1(int pass)
"@and @attr 4=2 @attr 1=1016 a "
"@attr 5=1 @attr 4=2 @attr 1=1016 b "));
+ YAZ_CHECK(tst_ccl_query(bibset, "title=a",
+ "@attr 1=/my/title a "));
+
+ YAZ_CHECK(tst_ccl_query(bibset, "comb=a",
+ "@or @attr 4=2 @attr 1=1016 a "
+ "@attr 1=/my/title a "));
+
/* Bug #2895 */
#if 1
YAZ_CHECK(tst_ccl_query(bibset, "a? b?",