Add new tests for motionless patterns
authorMichael Kay <mike@saxonica.com>
Tue, 15 Aug 2017 15:32:25 +0100
changeset 1740 fcd75b06c812
parent 1739 8ce663f30f4f
child 1741 03afa9383c55
Add new tests for motionless patterns
tests/attr/streamable/_streamable-test-set.xml
tests/attr/streamable/streamable-143.xsl
tests/attr/streamable/streamable-144.xsl
--- a/tests/attr/streamable/_streamable-test-set.xml	Tue Aug 15 15:31:56 2017 +0100
+++ b/tests/attr/streamable/_streamable-test-set.xml	Tue Aug 15 15:32:25 2017 +0100
@@ -2747,4 +2747,32 @@
       </result>
    </test-case>
    
+   <test-case name="streamable-143">
+      <description>match="p[1]" is not motionless</description>
+      <created by="Michael Kay" on="2017-08-14"/>
+      <environment>
+         <source role="." file="streamable-140.xml" streaming="true"/>
+      </environment>
+      <test>
+         <stylesheet file="streamable-143.xsl"/>
+      </test>
+      <result>
+         <error code="XTSE3430"/>
+      </result>
+   </test-case>
+   
+   <test-case name="streamable-144">
+      <description>match="p[last()]" is not motionless</description>
+      <created by="Michael Kay" on="2017-08-14"/>
+      <environment>
+         <source role="." file="streamable-140.xml" streaming="true"/>
+      </environment>
+      <test>
+         <stylesheet file="streamable-144.xsl"/>
+      </test>
+      <result>
+         <error code="XTSE3430"/>
+      </result>
+   </test-case>
+   
 </test-set>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/attr/streamable/streamable-143.xsl	Tue Aug 15 15:32:25 2017 +0100
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" 
+  xmlns:xs="http://www.w3.org/2001/XMLSchema" 
+  xmlns:math="http://www.w3.org/2005/xpath-functions/math" 
+  exclude-result-prefixes="xs math" 
+  version="3.0">
+  
+  <xsl:param name="STREAMABLE" as="xs:boolean" static="yes" select="true()"/>
+  
+  <xsl:mode _streamable="{$STREAMABLE}" on-no-match="shallow-copy"/>
+  
+  <xsl:template match="p[1]"/>
+  
+</xsl:stylesheet>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/attr/streamable/streamable-144.xsl	Tue Aug 15 15:32:25 2017 +0100
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" 
+  xmlns:xs="http://www.w3.org/2001/XMLSchema" 
+  xmlns:math="http://www.w3.org/2005/xpath-functions/math" 
+  exclude-result-prefixes="xs math" 
+  version="3.0">
+  
+  <xsl:param name="STREAMABLE" as="xs:boolean" static="yes" select="true()"/>
+  
+  <xsl:mode _streamable="{$STREAMABLE}" on-no-match="shallow-copy"/>
+  
+  <xsl:template match="p[last()]"/>
+  
+</xsl:stylesheet>
\ No newline at end of file