Skip to content

Commit

Permalink
pull in bug-fix release
Browse files Browse the repository at this point in the history
  • Loading branch information
sydb committed Apr 9, 2021
2 parents 73dbab7 + d669f6e commit ec6e6d8
Show file tree
Hide file tree
Showing 22 changed files with 12,485 additions and 5,688 deletions.
5 changes: 5 additions & 0 deletions Test/expected-results/oddbyexample.odd
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,11 @@
<attDef ident="scale" mode="delete"/>
</attList>
</classSpec>
<classSpec ident="att.interpLike" type="atts" mode="change">
<attList>
<attDef ident="inst" mode="delete"/>
</attList>
</classSpec>
<classSpec ident="att.naming" type="atts" mode="change">
<attList>
<attDef ident="role" mode="delete"/>
Expand Down
Binary file modified Test/expected-results/test.epub
Binary file not shown.
73 changes: 53 additions & 20 deletions Test/expected-results/test.isosch
Original file line number Diff line number Diff line change
Expand Up @@ -92,25 +92,43 @@ The element indicated by @spanTo (<value-of select="@spanTo"/>) must follow the
type="deprecationInfo"&gt;.</assert>
</rule>
</pattern>
<pattern id="schematron-constraint-test-ptr-ptrAtts-13">
<pattern id="schematron-constraint-test-rt-target-rt-target-not-span-13">
<rule context="tei:rt/@target">
<report test="../@from | ../@to">When target= is
present, neither from= nor to= should be.</report>
</rule>
</pattern>
<pattern id="schematron-constraint-test-rt-from-rt-from-14">
<rule context="tei:rt/@from">
<assert test="../@to">When from= is present, the to=
attribute of <name/> is required.</assert>
</rule>
</pattern>
<pattern id="schematron-constraint-test-rt-to-rt-to-15">
<rule context="tei:rt/@to">
<assert test="../@from">When to= is present, the from=
attribute of <name/> is required.</assert>
</rule>
</pattern>
<pattern id="schematron-constraint-test-ptr-ptrAtts-16">
<rule context="tei:ptr">
<report test="@target and @cRef">Only one of the
attributes @target and @cRef may be supplied on <name/>.</report>
</rule>
</pattern>
<pattern id="schematron-constraint-test-ref-refAtts-14">
<pattern id="schematron-constraint-test-ref-refAtts-17">
<rule context="tei:ref">
<report test="@target and @cRef">Only one of the
attributes @target' and @cRef' may be supplied on <name/>
</report>
</rule>
</pattern>
<pattern id="schematron-constraint-test-list-gloss-list-must-have-labels-15">
<pattern id="schematron-constraint-test-list-gloss-list-must-have-labels-18">
<rule context="tei:list[@type='gloss']">
<assert test="tei:label">The content of a "gloss" list should include a sequence of one or more pairs of a label element followed by an item element</assert>
</rule>
</pattern>
<pattern id="schematron-constraint-test-relatedItem-targetorcontent1-16">
<pattern id="schematron-constraint-test-relatedItem-targetorcontent1-19">
<rule context="tei:relatedItem">
<report test="@target and count( child::* ) &gt; 0">
If the @target attribute on <name/> is used, the
Expand All @@ -119,33 +137,48 @@ relatedItem element must be empty</report>
or a child element to indicate the related bibliographic item</assert>
</rule>
</pattern>
<pattern id="schematron-constraint-test-l-abstractModel-structure-l-17">
<pattern id="schematron-constraint-test-l-abstractModel-structure-l-20">
<rule context="tei:l">
<report test="ancestor::tei:l[not(.//tei:note//tei:l[. = current()])]">
Abstract model violation: Lines may not contain lines or lg elements.
</report>
</rule>
</pattern>
<pattern id="schematron-constraint-test-lg-atleast1oflggapl-18">
<pattern id="schematron-constraint-test-lg-atleast1oflggapl-21">
<rule context="tei:lg">
<assert test="count(descendant::tei:lg|descendant::tei:l|descendant::tei:gap) &gt; 0">An lg element
must contain at least one child l, lg, or gap element.</assert>
</rule>
</pattern>
<pattern id="schematron-constraint-test-lg-abstractModel-structure-l-19">
<pattern id="schematron-constraint-test-lg-abstractModel-structure-l-22">
<rule context="tei:lg">
<report test="ancestor::tei:l[not(.//tei:note//tei:lg[. = current()])]">
Abstract model violation: Lines may not contain line groups.
</report>
</rule>
</pattern>
<pattern id="schematron-constraint-test-quotation-quotationContents-20">
<pattern id="schematron-constraint-test-quotation-quotationContents-23">
<rule context="tei:quotation">
<report test="not(@marks) and not (tei:p)">
On <name/>, either the @marks attribute should be used, or a paragraph of description provided</report>
</rule>
</pattern>
<pattern id="schematron-constraint-test-path-pathmustnotbeclosed-21">
<pattern id="schematron-constraint-test-citeStructure-delim-citestructure-inner-delim-24">
<rule context="tei:citeStructure[parent::tei:citeStructure]">
<assert test="@delim">A <name/> with a parent <name/> must have a @delim attribute.</assert>
</rule>
</pattern>
<pattern id="schematron-constraint-test-citeStructure-match-citestructure-outer-match-25">
<rule context="tei:citeStructure[not(parent::tei:citeStructure)]">
<assert test="starts-with(@match,'/')">An XPath in @match on the outer <name/> must start with '/'.</assert>
</rule>
</pattern>
<pattern id="schematron-constraint-test-citeStructure-match-citestructure-inner-match-26">
<rule context="tei:citeStructure[parent::tei:citeStructure]">
<assert test="not(starts-with(@match,'/'))">An XPath in @match must not start with '/' except on the outer <name/>.</assert>
</rule>
</pattern>
<pattern id="schematron-constraint-test-path-pathmustnotbeclosed-27">
<rule context="tei:path[@points]">

<let name="firstPair" value="tokenize( normalize-space( @points ), ' ')[1]"/>
Expand All @@ -160,23 +193,23 @@ On <name/>, either the @marks attribute should be used, or a paragraph of descri
the zone element rather than the path element. </report>
</rule>
</pattern>
<pattern id="schematron-constraint-test-addSpan-spanTo-22">
<pattern id="schematron-constraint-test-addSpan-spanTo-28">
<rule context="tei:addSpan">
<assert test="@spanTo">The @spanTo attribute of <name/> is required.</assert>
</rule>
</pattern>
<pattern id="schematron-constraint-test-damageSpan-spanTo-24">
<pattern id="schematron-constraint-test-damageSpan-spanTo-30">
<rule context="tei:damageSpan">
<assert test="@spanTo">
The @spanTo attribute of <name/> is required.</assert>
</rule>
</pattern>
<pattern id="schematron-constraint-test-delSpan-spanTo-26">
<pattern id="schematron-constraint-test-delSpan-spanTo-32">
<rule context="tei:delSpan">
<assert test="@spanTo">The @spanTo attribute of <name/> is required.</assert>
</rule>
</pattern>
<pattern id="schematron-constraint-test-subst-substContents1-28">
<pattern id="schematron-constraint-test-subst-substContents1-34">
<rule context="tei:subst">
<assert test="child::tei:add and (child::tei:del or child::tei:surplus)">
<name/> must have at least one child add and at least one child del or surplus</assert>
Expand All @@ -186,48 +219,48 @@ The @spanTo attribute of <name/> is required.</assert>



<pattern id="schematron-constraint-test-div-abstractModel-structure-l-31">
<pattern id="schematron-constraint-test-div-abstractModel-structure-l-37">
<rule context="tei:div">
<report test="ancestor::tei:l">
Abstract model violation: Lines may not contain higher-level structural elements such as div.
</report>
</rule>
</pattern>
<pattern id="schematron-constraint-test-div-abstractModel-structure-p-32">
<pattern id="schematron-constraint-test-div-abstractModel-structure-p-38">
<rule context="tei:div">
<report test="ancestor::tei:p or ancestor::tei:ab and not(ancestor::tei:floatingText)">
Abstract model violation: p and ab may not contain higher-level structural elements such as div.
</report>
</rule>
</pattern>
<pattern id="schematron-constraint-test-link-linkTargets3-33">
<pattern id="schematron-constraint-test-link-linkTargets3-39">
<rule context="tei:link">
<assert test="contains(normalize-space(@target),' ')">You must supply at least two values for @target or on <name/>
</assert>
</rule>
</pattern>
<pattern id="schematron-constraint-test-ab-abstractModel-structure-ab-34">
<pattern id="schematron-constraint-test-ab-abstractModel-structure-ab-40">
<rule context="tei:ab">
<report test="not(ancestor::tei:floatingText) and (ancestor::tei:p or ancestor::tei:ab) and not(parent::tei:exemplum |parent::tei:item |parent::tei:note |parent::tei:q |parent::tei:quote |parent::tei:remarks |parent::tei:said |parent::tei:sp |parent::tei:stage |parent::tei:cell |parent::tei:figure)">
Abstract model violation: ab may not occur inside paragraphs or other ab elements.
</report>
</rule>
</pattern>
<pattern id="schematron-constraint-test-ab-abstractModel-structure-l-35">
<pattern id="schematron-constraint-test-ab-abstractModel-structure-l-41">
<rule context="tei:ab">
<report test="ancestor::tei:l or ancestor::tei:lg">
Abstract model violation: Lines may not contain higher-level divisions such as p or ab.
</report>
</rule>
</pattern>
<pattern id="schematron-constraint-test-join-joinTargets3-36">
<pattern id="schematron-constraint-test-join-joinTargets3-42">
<rule context="tei:join">
<assert test="contains(@target,' ')">
You must supply at least two values for @target on <name/>
</assert>
</rule>
</pattern>
<pattern id="schematron-constraint-test-standOff-nested_standOff_should_be_typed-37">
<pattern id="schematron-constraint-test-standOff-nested_standOff_should_be_typed-43">
<rule context="tei:standOff">
<assert test="@type or not(ancestor::tei:standOff)">This
<name/> element must have a @type attribute, since it is
Expand Down
Loading

0 comments on commit ec6e6d8

Please sign in to comment.