epubcheck-003
Tests the ex:epubcheck step error code.
Test is expected to pass.
The pipeline
<p:declare-step xmlns:cx="http://xmlcalabash.com/ns/extensions"
xmlns:err="http://www.w3.org/ns/xproc-error" xmlns:ex="http://exproc.org/ns/steps"
xmlns:p="http://www.w3.org/ns/xproc"
xmlns:t="http://xproc.org/ns/testsuite/3.0" version="3.0"
exclude-inline-prefixes="#all">
<p:import href="https://xmlcalabash.com/ext/library/epubcheck.xpl"/>
<p:output port="result"/>
<p:try>
<ex:epubcheck name="epubcheck"
assert-valid="true">
<p:with-input href="../epubcheck/epub-001.epub"/>
</ex:epubcheck>
<p:catch code="Q{http://exproc.org/ns/error}XC0001">
<p:identity>
<p:with-input>
<pass/>
</p:with-input>
</p:identity>
</p:catch>
</p:try>
</p:declare-step>
Result
<pass xmlns:t="http://xproc.org/ns/testsuite/3.0"/>
Schematron checks
<s:schema xmlns:s="http://purl.oclc.org/dsdl/schematron"
xmlns:t="http://xproc.org/ns/testsuite/3.0" queryBinding="xslt2">
<s:ns prefix="xvrl"
uri="http://www.xproc.org/ns/xvrl"/>
<s:pattern>
<s:rule context="/">
<s:assert test="pass">Test failed</s:assert>
</s:rule>
</s:pattern>
</s:schema>
Revision history
- 16 Nov 2025, Norm Tovey-Walsh
- Created test.