summaryrefslogtreecommitdiffstats
path: root/test/xml-mapped/content-namespace-2
diff options
context:
space:
mode:
Diffstat (limited to 'test/xml-mapped/content-namespace-2')
-rw-r--r--test/xml-mapped/content-namespace-2/check-nomap.txt12
-rw-r--r--test/xml-mapped/content-namespace-2/check.txt12
-rw-r--r--test/xml-mapped/content-namespace-2/input.xml22
-rw-r--r--test/xml-mapped/content-namespace-2/map.xml13
4 files changed, 59 insertions, 0 deletions
diff --git a/test/xml-mapped/content-namespace-2/check-nomap.txt b/test/xml-mapped/content-namespace-2/check-nomap.txt
new file mode 100644
index 0000000..d7c6de8
--- /dev/null
+++ b/test/xml-mapped/content-namespace-2/check-nomap.txt
@@ -0,0 +1,12 @@
+range-0/0/0:string:"ns2:date"
+range-0/0/1:string:"ns2:category"
+range-0/0/2:string:"ns2:amount"
+range-0/1/0:string:"2011-01-02"
+range-0/1/1:string:"Lunch"
+range-0/1/2:numeric:6.32
+range-0/2/0:string:"2011-01-03"
+range-0/2/1:string:"Lunch"
+range-0/2/2:numeric:7.45
+range-0/3/0:string:"2011-01-04"
+range-0/3/1:string:"Gas"
+range-0/3/2:numeric:44.35
diff --git a/test/xml-mapped/content-namespace-2/check.txt b/test/xml-mapped/content-namespace-2/check.txt
new file mode 100644
index 0000000..a4c7237
--- /dev/null
+++ b/test/xml-mapped/content-namespace-2/check.txt
@@ -0,0 +1,12 @@
+data/2/0:string:"ns2:date"
+data/2/1:string:"ns2:category"
+data/2/2:string:"ns2:amount"
+data/3/0:string:"2011-01-02"
+data/3/1:string:"Lunch"
+data/3/2:numeric:6.32
+data/4/0:string:"2011-01-03"
+data/4/1:string:"Lunch"
+data/4/2:numeric:7.45
+data/5/0:string:"2011-01-04"
+data/5/1:string:"Gas"
+data/5/2:numeric:44.35
diff --git a/test/xml-mapped/content-namespace-2/input.xml b/test/xml-mapped/content-namespace-2/input.xml
new file mode 100644
index 0000000..435dfce
--- /dev/null
+++ b/test/xml-mapped/content-namespace-2/input.xml
@@ -0,0 +1,22 @@
+<?xml version="1.0"?>
+<a:data xmlns:a="http://namespace-1">
+ <b:monthly xmlns:b="http://namespace-2" xmlns:c="http://namespace-3">
+ <b:entries>
+ <b:entry>
+ <c:date>2011-01-02</c:date>
+ <c:category>Lunch</c:category>
+ <c:amount>6.32</c:amount>
+ </b:entry>
+ <b:entry>
+ <c:date>2011-01-03</c:date>
+ <c:category>Lunch</c:category>
+ <c:amount>7.45</c:amount>
+ </b:entry>
+ <b:entry>
+ <c:date>2011-01-04</c:date>
+ <c:category>Gas</c:category>
+ <c:amount>44.35</c:amount>
+ </b:entry>
+ </b:entries>
+ </b:monthly>
+</a:data>
diff --git a/test/xml-mapped/content-namespace-2/map.xml b/test/xml-mapped/content-namespace-2/map.xml
new file mode 100644
index 0000000..172de50
--- /dev/null
+++ b/test/xml-mapped/content-namespace-2/map.xml
@@ -0,0 +1,13 @@
+<?xml version="1.0"?>
+<map xmlns="http://gitorious.org/orcus/xml-map">
+ <ns alias="x" uri="http://namespace-1"/>
+ <ns alias="y" uri="http://namespace-2"/>
+ <ns alias="z" uri="http://namespace-3"/>
+ <sheet name="data"/>
+ <range row="2" column="0" sheet="data">
+ <field path="/x:data/y:monthly/y:entries/y:entry/z:date"/>
+ <field path="/x:data/y:monthly/y:entries/y:entry/z:category"/>
+ <field path="/x:data/y:monthly/y:entries/y:entry/z:amount"/>
+ <row-group path="/x:data/y:monthly/y:entries/y:entry"/>
+ </range>
+</map>