<?xml version="1.0" encoding="utf-8"?>
<t:test xmlns:t="http://xproc.org/ns/testsuite/3.0"
        xml:base="/nw-make-absolute-uris-003.xml"
        name="nw-make-absolute-uris-003.xml"
        expected="pass">
   <t:info xmlns:err="http://www.w3.org/ns/xproc-error">
      <t:title>p:make-absolute-uris 003 (NW)</t:title>
      <t:revision-history>
         <t:revision>
            <t:date>2025-05-23</t:date>
            <t:author>
               <t:name>Norman Walsh</t:name>
            </t:author>
            <t:description xmlns="http://www.w3.org/1999/xhtml">
               <p>Removed spurious feature.</p>
            </t:description>
         </t:revision>
         <t:revision>
            <t:date>2024-05-15</t:date>
            <t:author>
               <t:name>Norman Walsh</t:name>
            </t:author>
            <t:description xmlns="http://www.w3.org/1999/xhtml">
               <p>Add test for p:make-absolute-uris.</p>
            </t:description>
         </t:revision>
      </t:revision-history>
   </t:info>
   <t:description xmlns="http://www.w3.org/1999/xhtml"
                  xmlns:err="http://www.w3.org/ns/xproc-error">
      <p>Use an explicit base URI.</p>
   </t:description>
   <t:pipeline xmlns:err="http://www.w3.org/ns/xproc-error">
      <p:declare-step xmlns:c="http://www.w3.org/ns/xproc-step"
                      xmlns:p="http://www.w3.org/ns/xproc"
                      xmlns:xs="http://www.w3.org/2001/XMLSchema"
                      exclude-inline-prefixes="#all"
                      version="3.0">
         <p:output port="result"/>
         <p:make-absolute-uris match="info/@uri" base-uri="http://example.com/abs/">
            <p:with-input>
               <doc>
                  <info uri="value"/>
               </doc>
            </p:with-input>
         </p:make-absolute-uris>
      </p:declare-step>
   </t:pipeline>
   <t:schematron xmlns:err="http://www.w3.org/ns/xproc-error">
      <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:ns prefix="c" uri="http://www.w3.org/ns/xproc-step"/>
         <s:pattern>
            <s:rule context="/*">
               <s:assert test="self::doc">The root is not doc.</s:assert>
               <s:assert test="info/@uri = 'http://example.com/abs/value'">The uri is incorrect.</s:assert>
            </s:rule>
         </s:pattern>
      </s:schema>
   </t:schematron>
   <t:result name="nw-make-absolute-uris-003.xml">
      <doc>
         <info uri="http://example.com/abs/value"/>
      </doc>
   </t:result>
</t:test>
