bom-009
Tests that the BOM isn’t interpreted in an ISO-8859-1 document.
Test is expected to pass.
The pipeline
<p:declare-step xmlns:p="http://www.w3.org/ns/xproc"
xmlns:t="http://xproc.org/ns/testsuite/3.0" version="3.0">
<p:output port="result"/>
<p:option name="WHOST"
select="'http://localhost:8246'" static="true"/>
<p:identity>
<p:with-input>
<p:document content-type="text/plain"
href="{$WHOST}/docs/not-a-bom.txt"/>
</p:with-input>
</p:identity>
<p:identity>
<p:with-input>
<p:inline>
<result>{starts-with(., 'It')}</result>
</p:inline>
</p:with-input>
</p:identity>
</p:declare-step>
Result
<result xmlns:t="http://xproc.org/ns/testsuite/3.0">true</result>
Schematron checks
<s:schema xmlns="http://www.w3.org/1999/xhtml"
xmlns:s="http://purl.oclc.org/dsdl/schematron" xmlns:t="http://xproc.org/ns/testsuite/3.0"
queryBinding="xslt2">
<s:ns uri="http://www.w3.org/1999/xhtml"
prefix="html"/>
<s:pattern>
<s:rule context="/">
<s:assert test="result='true'">The BOM was removed.</s:assert>
</s:rule>
</s:pattern>
</s:schema>
Revision history
- 23 May 2025, Norm Tovey-Walsh
- Added static options for web server host and port.
- 05 Feb 2025, Norm Tovey-Walsh
- Initial commit.