p:document 002

Tests p:document with a relative uri in @href: Base uri of p:document to be used.

Test ab-p-document002.xml is expected to pass.

It requires the following features: webaccess.

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>
         <p:document href="learning.html" xml:base="http://xproc.org/"/>
      </p:with-input>
   </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 uri="http://www.w3.org/1999/xhtml" prefix="html"/>
   <s:pattern>
      <s:rule context="/">
         <s:assert test="html:html/html:head/html:title='XProc - Learning'">Element hmtl/head/title is not 'XProc - Learning'.</s:assert>
      </s:rule>
   </s:pattern>
</s:schema>

Revision history

19 Sep 2024, Achim Berndzen

Changed expected document title due to change of website.

10 Jun 2021, Achim Berndzen

Added attribute 'queryBinding' to schematron's schema.

11 Jun 2020, Achim Berndzen

Changed test as a consequence of removing of xproc.org/about.html.

31 Aug 2019, Achim Berndzen

Change target for http-request to xproc.org.

03 Apr 2018 16:57, Achim Berndzen

Some new tests.