From df4b5db6118ebfe14c00469befbeeb1e9d57c21a Mon Sep 17 00:00:00 2001
From: Adam Radziszewski <adam.radziszewski@pwr.wroc.pl>
Date: Thu, 5 May 2011 16:10:11 +0200
Subject: [PATCH] mark head test

---
 tests/rules-data/match/head/cclmatch.xml      | 62 ++++++++++++++++
 tests/rules-data/match/head/cclmatch1.ccl     | 13 ++++
 tests/rules-data/match/head/cclmatch1.out.xml | 74 +++++++++++++++++++
 .../match/head/simple.is-the-tagset           |  1 +
 4 files changed, 150 insertions(+)
 create mode 100644 tests/rules-data/match/head/cclmatch.xml
 create mode 100644 tests/rules-data/match/head/cclmatch1.ccl
 create mode 100644 tests/rules-data/match/head/cclmatch1.out.xml
 create mode 100644 tests/rules-data/match/head/simple.is-the-tagset

diff --git a/tests/rules-data/match/head/cclmatch.xml b/tests/rules-data/match/head/cclmatch.xml
new file mode 100644
index 0000000..97422c1
--- /dev/null
+++ b/tests/rules-data/match/head/cclmatch.xml
@@ -0,0 +1,62 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE cesAna SYSTEM "xcesAnaIPI.dtd">
+<cesAna xmlns:xlink="http://www.w3.org/1999/xlink" version="1.0" type="lex disamb">
+<chunkList>
+ <chunk>
+  <sentence>
+   <tok>
+    <orth>Tu</orth>
+    <lex><base>tu</base><ctag>qub</ctag></lex>
+   </tok>
+   <tok>
+    <orth>jest</orth>
+    <lex><base>być</base><ctag>verb</ctag></lex>
+   </tok>
+   <tok>
+    <orth>czarny</orth>
+    <lex><base>czarny</base><ctag>adj</ctag></lex>
+   </tok>
+   <tok>
+    <orth>błyszczący</orth>
+    <lex><base>błyszczeć</base><ctag>adj</ctag></lex>
+   </tok>
+   <tok>
+    <orth>głośnik</orth>
+    <lex><base>głośnik</base><ctag>noun</ctag></lex>
+   </tok>
+   <ns/>
+   <tok>
+    <orth>.</orth>
+    <lex><base>.</base><ctag>interp</ctag></lex>
+   </tok>
+  </sentence>
+  <sentence>
+   <tok>
+    <orth>Tam</orth>
+    <lex><base>tam</base><ctag>qub</ctag></lex>
+   </tok>
+   <tok>
+    <orth>jest</orth>
+    <lex><base>być</base><ctag>verb</ctag></lex>
+   </tok>
+   <tok>
+    <orth>nowa</orth>
+    <lex><base>nowy</base><ctag>adj</ctag></lex>
+   </tok>
+   <tok>
+    <orth>pompa</orth>
+    <lex><base>pompa</base><ctag>noun</ctag></lex>
+   </tok>
+   <tok>
+    <orth>próżniowa</orth>
+    <lex><base>próżniowy</base><ctag>adj</ctag></lex>
+   </tok>
+   <ns/>
+   <tok>
+    <orth>.</orth>
+    <lex><base>.</base><ctag>interp</ctag></lex>
+   </tok>
+  </sentence>
+ </chunk>
+</chunkList>
+</cesAna>
diff --git a/tests/rules-data/match/head/cclmatch1.ccl b/tests/rules-data/match/head/cclmatch1.ccl
new file mode 100644
index 0000000..7c7aa47
--- /dev/null
+++ b/tests/rules-data/match/head/cclmatch1.ccl
@@ -0,0 +1,13 @@
+apply
+(
+  match
+  (
+    optional(repeat(equal(class[0], {adj}))),
+    equal(class[0], {noun}),
+    optional(repeat(equal(class[0], {adj})))
+  ),
+  actions
+  (
+    mark(M, M, :2, "NP")
+  )
+)
diff --git a/tests/rules-data/match/head/cclmatch1.out.xml b/tests/rules-data/match/head/cclmatch1.out.xml
new file mode 100644
index 0000000..b6871bd
--- /dev/null
+++ b/tests/rules-data/match/head/cclmatch1.out.xml
@@ -0,0 +1,74 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE cesAna SYSTEM "xcesAnaIPI.dtd">
+<cesAna xmlns:xlink="http://www.w3.org/1999/xlink" version="1.0" type="lex disamb">
+<chunkList>
+ <chunk>
+  <sentence>
+   <tok>
+    <orth>Tu</orth>
+    <lex><base>tu</base><ctag>qub</ctag></lex>
+    <ann chan="NP">0</ann>
+   </tok>
+   <tok>
+    <orth>jest</orth>
+    <lex><base>być</base><ctag>verb</ctag></lex>
+    <ann chan="NP">0</ann>
+   </tok>
+   <tok>
+    <orth>czarny</orth>
+    <lex><base>czarny</base><ctag>adj</ctag></lex>
+    <ann chan="NP">1</ann>
+   </tok>
+   <tok>
+    <orth>błyszczący</orth>
+    <lex><base>błyszczeć</base><ctag>adj</ctag></lex>
+    <ann chan="NP">1</ann>
+   </tok>
+   <tok>
+    <orth>głośnik</orth>
+    <lex><base>głośnik</base><ctag>noun</ctag></lex>
+    <ann chan="NP" head="1">1</ann>
+   </tok>
+   <ns/>
+   <tok>
+    <orth>.</orth>
+    <lex><base>.</base><ctag>interp</ctag></lex>
+    <ann chan="NP">0</ann>
+   </tok>
+  </sentence>
+  <sentence>
+   <tok>
+    <orth>Tam</orth>
+    <lex><base>tam</base><ctag>qub</ctag></lex>
+    <ann chan="NP">0</ann>
+   </tok>
+   <tok>
+    <orth>jest</orth>
+    <lex><base>być</base><ctag>verb</ctag></lex>
+    <ann chan="NP">0</ann>
+   </tok>
+   <tok>
+    <orth>nowa</orth>
+    <lex><base>nowy</base><ctag>adj</ctag></lex>
+    <ann chan="NP">1</ann>
+   </tok>
+   <tok>
+    <orth>pompa</orth>
+    <lex><base>pompa</base><ctag>noun</ctag></lex>
+    <ann chan="NP" head="1">1</ann>
+   </tok>
+   <tok>
+    <orth>próżniowa</orth>
+    <lex><base>próżniowy</base><ctag>adj</ctag></lex>
+    <ann chan="NP">1</ann>
+   </tok>
+   <ns/>
+   <tok>
+    <orth>.</orth>
+    <lex><base>.</base><ctag>interp</ctag></lex>
+    <ann chan="NP">0</ann>
+   </tok>
+  </sentence>
+ </chunk>
+</chunkList>
+</cesAna>
diff --git a/tests/rules-data/match/head/simple.is-the-tagset b/tests/rules-data/match/head/simple.is-the-tagset
new file mode 100644
index 0000000..8b13789
--- /dev/null
+++ b/tests/rules-data/match/head/simple.is-the-tagset
@@ -0,0 +1 @@
+
-- 
GitLab