iXML Community Group Test Suite

23 Oct 2023 (22 Nov 2023)

Top-level catalog for tests in the iXML Community Group Test Suite.

Tests have been contributed from several sources, but the core of the test collection are the tests contributed by Steven Pemberton in December 2021.

Misc tests 2

28 Jun 2022

Grammars 21-40.

Test grammars compiled manually in 2018 and 2019, re-packaged in 2022.

Added test cases where needed and moved to ixml test collection, June 2022.

sample.grammar.25

Created 08 Feb 2022 by cmsmcq

Another grammar with infinite ambiguity. This one has some non-terminals which occur only inside loops (so a ruthless policy of omitting all loops will never exhibit parse trees with them).

Invisible XML Grammar


          S: A, B, C,
             D, (Z, C, D)*,
             E, (Y, B, C, D, (Z, C, D)*, E)*,
             F, (X, B, C, D, (Z, C, D)*, E, (Y, B, C, D, (Z, C, D)*, E)*, F )*,
             G, (W, A, B, C,
                D, (Z, C, D)*,
                E, (Y, B, C, D, (Z, C, D)*, E)*,
                F, (X, B, C, D, (Z, C, D)*, E, (Y, B, C, D, (Z, C, D)*, E)*, F )*, G)*.
          A: {nil}.  B: {nil}.  C: {nil}.  D: {nil}.  E: {nil}.  F: {nil}.  G: {nil}.
          Z: {nil}. Y: {nil}. X: {nil}. W: {nil}.
    

Test case: Grammar test

Repository URI: …/tests/misc/misc-021-040-catalog.xml

Expected result

<ixml xmlns:ixml="http://invisiblexml.org/NS"
       xmlns:tc="https://github.com/invisibleXML/ixml/test-catalog">
   <rule name="S">
      <alt>
         <nonterminal name="A"/>
         <nonterminal name="B"/>
         <nonterminal name="C"/>
         <nonterminal name="D"/>
         <repeat0>
            <alts>
               <alt>
                  <nonterminal name="Z"/>
                  <nonterminal name="C"/>
                  <nonterminal name="D"/>
               </alt>
            </alts>
         </repeat0>
         <nonterminal name="E"/>
         <repeat0>
            <alts>
               <alt>
                  <nonterminal name="Y"/>
                  <nonterminal name="B"/>
                  <nonterminal name="C"/>
                  <nonterminal name="D"/>
                  <repeat0>
                     <alts>
                        <alt>
                           <nonterminal name="Z"/>
                           <nonterminal name="C"/>
                           <nonterminal name="D"/>
                        </alt>
                     </alts>
                  </repeat0>
                  <nonterminal name="E"/>
               </alt>
            </alts>
         </repeat0>
         <nonterminal name="F"/>
         <repeat0>
            <alts>
               <alt>
                  <nonterminal name="X"/>
                  <nonterminal name="B"/>
                  <nonterminal name="C"/>
                  <nonterminal name="D"/>
                  <repeat0>
                     <alts>
                        <alt>
                           <nonterminal name="Z"/>
                           <nonterminal name="C"/>
                           <nonterminal name="D"/>
                        </alt>
                     </alts>
                  </repeat0>
                  <nonterminal name="E"/>
                  <repeat0>
                     <alts>
                        <alt>
                           <nonterminal name="Y"/>
                           <nonterminal name="B"/>
                           <nonterminal name="C"/>
                           <nonterminal name="D"/>
                           <repeat0>
                              <alts>
                                 <alt>
                                    <nonterminal name="Z"/>
                                    <nonterminal name="C"/>
                                    <nonterminal name="D"/>
                                 </alt>
                              </alts>
                           </repeat0>
                           <nonterminal name="E"/>
                        </alt>
                     </alts>
                  </repeat0>
                  <nonterminal name="F"/>
               </alt>
            </alts>
         </repeat0>
         <nonterminal name="G"/>
         <repeat0>
            <alts>
               <alt>
                  <nonterminal name="W"/>
                  <nonterminal name="A"/>
                  <nonterminal name="B"/>
                  <nonterminal name="C"/>
                  <nonterminal name="D"/>
                  <repeat0>
                     <alts>
                        <alt>
                           <nonterminal name="Z"/>
                           <nonterminal name="C"/>
                           <nonterminal name="D"/>
                        </alt>
                     </alts>
                  </repeat0>
                  <nonterminal name="E"/>
                  <repeat0>
                     <alts>
                        <alt>
                           <nonterminal name="Y"/>
                           <nonterminal name="B"/>
                           <nonterminal name="C"/>
                           <nonterminal name="D"/>
                           <repeat0>
                              <alts>
                                 <alt>
                                    <nonterminal name="Z"/>
                                    <nonterminal name="C"/>
                                    <nonterminal name="D"/>
                                 </alt>
                              </alts>
                           </repeat0>
                           <nonterminal name="E"/>
                        </alt>
                     </alts>
                  </repeat0>
                  <nonterminal name="F"/>
                  <repeat0>
                     <alts>
                        <alt>
                           <nonterminal name="X"/>
                           <nonterminal name="B"/>
                           <nonterminal name="C"/>
                           <nonterminal name="D"/>
                           <repeat0>
                              <alts>
                                 <alt>
                                    <nonterminal name="Z"/>
                                    <nonterminal name="C"/>
                                    <nonterminal name="D"/>
                                 </alt>
                              </alts>
                           </repeat0>
                           <nonterminal name="E"/>
                           <repeat0>
                              <alts>
                                 <alt>
                                    <nonterminal name="Y"/>
                                    <nonterminal name="B"/>
                                    <nonterminal name="C"/>
                                    <nonterminal name="D"/>
                                    <repeat0>
                                       <alts>
                                          <alt>
                                             <nonterminal name="Z"/>
                                             <nonterminal name="C"/>
                                             <nonterminal name="D"/>
                                          </alt>
                                       </alts>
                                    </repeat0>
                                    <nonterminal name="E"/>
                                 </alt>
                              </alts>
                           </repeat0>
                           <nonterminal name="F"/>
                        </alt>
                     </alts>
                  </repeat0>
                  <nonterminal name="G"/>
               </alt>
            </alts>
         </repeat0>
      </alt>
   </rule>
   <rule name="A">
      <comment>nil</comment>
      <alt/>
   </rule>
   <rule name="B">
      <comment>nil</comment>
      <alt/>
   </rule>
   <rule name="C">
      <comment>nil</comment>
      <alt/>
   </rule>
   <rule name="D">
      <comment>nil</comment>
      <alt/>
   </rule>
   <rule name="E">
      <comment>nil</comment>
      <alt/>
   </rule>
   <rule name="F">
      <comment>nil</comment>
      <alt/>
   </rule>
   <rule name="G">
      <comment>nil</comment>
      <alt/>
   </rule>
   <rule name="Z">
      <comment>nil</comment>
      <alt/>
   </rule>
   <rule name="Y">
      <comment>nil</comment>
      <alt/>
   </rule>
   <rule name="X">
      <comment>nil</comment>
      <alt/>
   </rule>
   <rule name="W">
      <comment>nil</comment>
      <alt/>
   </rule>
</ixml>