with-input-select-009

Tests select on p:with-input and no explicit connection is connected to the default readable port.

Test ab-with-input-select-009.xml is expected to pass.

The pipeline


<p:declare-step xmlns:p="http://www.w3.org/ns/xproc" version="3.0">
   <p:output port="result"/>
   <p:identity>
      <p:with-input>
         <doc>
            <element/>
         </doc>
      </p:with-input>
   </p:identity>
   <p:identity>
      <p:with-input select="/doc/element"/>
   </p:identity>
</p:declare-step>
MorganaXProc passing XML Calabash passing

Schematron validation


<s:schema xmlns="http://www.w3.org/1999/xhtml" xmlns:s="http://purl.oclc.org/dsdl/schematron" queryBinding="xslt2">
   <s:ns prefix="p" uri="http://www.w3.org/ns/xproc"/>
   <s:pattern>
      <s:rule context="/">
         <s:assert test="count(*) = 1">Document does not have exactly one child element.</s:assert>
         <s:assert test="*[1]/name()='element'">Root element is not named 'element'.</s:assert>
      </s:rule>
   </s:pattern>
</s:schema>

Revision history

10 Jun 2021, Achim Berndzen

Added attribute 'queryBinding' to schematron's schema.

02 May 2018 18:16, Achim Berndzen

Change test with document-properties to map{xs:QName, item()}