summaryrefslogtreecommitdiffstats
path: root/test/xml-mapped/attribute-namespace
diff options
context:
space:
mode:
Diffstat (limited to 'test/xml-mapped/attribute-namespace')
-rw-r--r--test/xml-mapped/attribute-namespace/check-nomap.txt12
-rw-r--r--test/xml-mapped/attribute-namespace/check.txt12
-rw-r--r--test/xml-mapped/attribute-namespace/input.xml8
-rw-r--r--test/xml-mapped/attribute-namespace/map.xml12
4 files changed, 44 insertions, 0 deletions
diff --git a/test/xml-mapped/attribute-namespace/check-nomap.txt b/test/xml-mapped/attribute-namespace/check-nomap.txt
new file mode 100644
index 0000000..63fe3cc
--- /dev/null
+++ b/test/xml-mapped/attribute-namespace/check-nomap.txt
@@ -0,0 +1,12 @@
+range-0/0/0:string:"ns1:date-received"
+range-0/0/1:string:"ns1:date-processed"
+range-0/0/2:string:"ns1:received-by"
+range-0/1/0:string:"2011-01-01"
+range-0/1/1:string:"2011-01-03"
+range-0/1/2:string:"JKB"
+range-0/2/0:string:"2011-01-01"
+range-0/2/1:string:"2011-01-04"
+range-0/2/2:string:"CJ"
+range-0/3/0:string:"2011-12-23"
+range-0/3/1:string:"2012-01-01"
+range-0/3/2:string:"KY"
diff --git a/test/xml-mapped/attribute-namespace/check.txt b/test/xml-mapped/attribute-namespace/check.txt
new file mode 100644
index 0000000..c8f23a3
--- /dev/null
+++ b/test/xml-mapped/attribute-namespace/check.txt
@@ -0,0 +1,12 @@
+data/1/1:string:"ns1:date-received"
+data/1/2:string:"ns1:date-processed"
+data/1/3:string:"ns1:received-by"
+data/2/1:string:"2011-01-01"
+data/2/2:string:"2011-01-03"
+data/2/3:string:"JKB"
+data/3/1:string:"2011-01-01"
+data/3/2:string:"2011-01-04"
+data/3/3:string:"CJ"
+data/4/1:string:"2011-12-23"
+data/4/2:string:"2012-01-01"
+data/4/3:string:"KY"
diff --git a/test/xml-mapped/attribute-namespace/input.xml b/test/xml-mapped/attribute-namespace/input.xml
new file mode 100644
index 0000000..4a29806
--- /dev/null
+++ b/test/xml-mapped/attribute-namespace/input.xml
@@ -0,0 +1,8 @@
+<?xml version="1.0"?>
+<a:data xmlns:a="http://ns-1" xmlns:b="http://ns-2">
+ <b:entries>
+ <b:entry b:date-received="2011-01-01" b:date-processed="2011-01-03" b:received-by="JKB"/>
+ <b:entry b:date-received="2011-01-01" b:date-processed="2011-01-04" b:received-by="CJ"/>
+ <b:entry b:date-received="2011-12-23" b:date-processed="2012-01-01" b:received-by="KY"/>
+ </b:entries>
+</a:data>
diff --git a/test/xml-mapped/attribute-namespace/map.xml b/test/xml-mapped/attribute-namespace/map.xml
new file mode 100644
index 0000000..76e5b72
--- /dev/null
+++ b/test/xml-mapped/attribute-namespace/map.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0"?>
+<map xmlns="http://gitorious.org/orcus/xml-map">
+ <ns alias="x" uri="http://ns-1"/>
+ <ns alias="y" uri="http://ns-2"/>
+ <sheet name="data"/>
+ <range row="1" column="1" sheet="data">
+ <field path="/x:data/y:entries/y:entry/@y:date-received"/>
+ <field path="/x:data/y:entries/y:entry/@y:date-processed"/>
+ <field path="/x:data/y:entries/y:entry/@y:received-by"/>
+ <row-group path="/x:data/y:entries/y:entry"/>
+ </range>
+</map>