Test results for Linux

test_003062_rnc_multitree_3

Test description

Test for element sequence number handling, wildcard handling, and
hierarchical element handling with element records that have more
than one structure in a complex RNC schema.

Test status

 Pass

Run command

cat _INPUT_DATA_ ¦ xmlfy -S schema.rnc -A number

Input data

1
1 2
1 2 3
1 2 3 4
1 2 3 4 5
1 2 3 4 5 6
1 2 3 4 5 6 7
1 2 3 4 5 6 7 8
1 2 3 4 5 6 7 8 9
1 2 3 4 5 6 7 8 9 10
1 2 3 4 5 6 7 8 9 10 11
1 2 3 4 5 6 7 8 9 10 11 12
1 2 3 4 5 6 7 8 9 10 11 12 13
1 2 3 4 5 6 7 8 9 10 11 12 13 14
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20

Schema

start = multitree
multitree = element multitree { rec_A* }
rec_A = element rec_A { branch0, rec_AA, b, c, rec_BB, rec_BB, rec_CCC, rec_BB, rec_BBB* }
rec_A ¦= element rec_A { branch1, c, rec_BB }
rec_AA = element rec_AA { branch0 }
rec_AA ¦= element rec_AA { branch1, rec_AAA, b }
rec_AAA = element rec_AAA { branch0 }
rec_AAA ¦= element rec_AAA { branch1 }
rec_BB = element rec_BB { branch0, rec_BBB }
rec_BB ¦= element rec_BB { branch1, rec_CCC }
rec_BBB = element rec_BBB { branch0 }
rec_BBB ¦= element rec_BBB { branch1, b }
rec_CCC = element rec_CCC { branch0, b }
rec_CCC ¦= element rec_CCC { branch1, rec_DDDD }
rec_CCC ¦= element rec_CCC { branch2 }
rec_DDDD = element rec_DDDD { branch0, a }
a = element a { text }
b = element b { text }
c = element c { text }
branch0 = element branch0 { text }
branch1 = element branch1 { text }
branch2 = element branch2 { text }

Output result

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE multitree SYSTEM "schema.rnc">
<multitree>
  <rec_A number="1">
    <branch1 number="1">1</branch1>
    <c number="1">2</c>
    <rec_BB number="1">
      <branch0 number="1">3</branch0>
      <rec_BBB number="1">
        <branch0 number="1">4</branch0>
      </rec_BBB>
    </rec_BB>
  </rec_A>
  <rec_A number="2">
    <branch1 number="1">1</branch1>
    <c number="1">2</c>
    <rec_BB number="1">
      <branch0 number="1">3</branch0>
      <rec_BBB number="1">
        <branch1 number="1">4</branch1>
        <b number="1">5</b>
      </rec_BBB>
    </rec_BB>
  </rec_A>
  <rec_A number="3">
    <branch1 number="1">1</branch1>
    <c number="1">2</c>
    <rec_BB number="1">
      <branch1 number="1">3</branch1>
      <rec_CCC number="1">
        <branch1 number="1">4</branch1>
        <rec_DDDD number="1">
          <branch0 number="1">5</branch0>
          <a number="1">6</a>
        </rec_DDDD>
      </rec_CCC>
    </rec_BB>
  </rec_A>
  <rec_A number="4">
    <branch0 number="1">1</branch0>
    <rec_AA number="1">
      <branch0 number="1">2</branch0>
    </rec_AA>
    <b number="1">3</b>
    <c number="1">4</c>
    <rec_BB number="1">
      <branch0 number="1">5</branch0>
      <rec_BBB number="1">
        <branch0 number="1">6</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_BB number="2">
      <branch0 number="1">7</branch0>
      <rec_BBB number="1">
        <branch0 number="1">8</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_CCC number="1">
      <branch2 number="1">9</branch2>
    </rec_CCC>
    <rec_BB number="3">
      <branch0 number="1">10</branch0>
      <rec_BBB number="1">
        <branch0 number="1">11</branch0>
      </rec_BBB>
    </rec_BB>
  </rec_A>
  <rec_A number="5">
    <branch0 number="1">1</branch0>
    <rec_AA number="1">
      <branch0 number="1">2</branch0>
    </rec_AA>
    <b number="1">3</b>
    <c number="1">4</c>
    <rec_BB number="1">
      <branch0 number="1">5</branch0>
      <rec_BBB number="1">
        <branch0 number="1">6</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_BB number="2">
      <branch0 number="1">7</branch0>
      <rec_BBB number="1">
        <branch0 number="1">8</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_CCC number="1">
      <branch0 number="1">9</branch0>
      <b number="1">10</b>
    </rec_CCC>
    <rec_BB number="3">
      <branch0 number="1">11</branch0>
      <rec_BBB number="1">
        <branch0 number="1">12</branch0>
      </rec_BBB>
    </rec_BB>
  </rec_A>
  <rec_A number="6">
    <branch0 number="1">1</branch0>
    <rec_AA number="1">
      <branch0 number="1">2</branch0>
    </rec_AA>
    <b number="1">3</b>
    <c number="1">4</c>
    <rec_BB number="1">
      <branch0 number="1">5</branch0>
      <rec_BBB number="1">
        <branch0 number="1">6</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_BB number="2">
      <branch0 number="1">7</branch0>
      <rec_BBB number="1">
        <branch0 number="1">8</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_CCC number="1">
      <branch0 number="1">9</branch0>
      <b number="1">10</b>
    </rec_CCC>
    <rec_BB number="3">
      <branch0 number="1">11</branch0>
      <rec_BBB number="1">
        <branch0 number="1">12</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_BBB number="1">
      <branch0 number="1">13</branch0>
    </rec_BBB>
  </rec_A>
  <rec_A number="7">
    <branch0 number="1">1</branch0>
    <rec_AA number="1">
      <branch0 number="1">2</branch0>
    </rec_AA>
    <b number="1">3</b>
    <c number="1">4</c>
    <rec_BB number="1">
      <branch0 number="1">5</branch0>
      <rec_BBB number="1">
        <branch0 number="1">6</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_BB number="2">
      <branch0 number="1">7</branch0>
      <rec_BBB number="1">
        <branch0 number="1">8</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_CCC number="1">
      <branch0 number="1">9</branch0>
      <b number="1">10</b>
    </rec_CCC>
    <rec_BB number="3">
      <branch0 number="1">11</branch0>
      <rec_BBB number="1">
        <branch0 number="1">12</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_BBB number="1">
      <branch0 number="1">13</branch0>
    </rec_BBB>
    <rec_BBB number="2">
      <branch0 number="1">14</branch0>
    </rec_BBB>
  </rec_A>
  <rec_A number="8">
    <branch0 number="1">1</branch0>
    <rec_AA number="1">
      <branch0 number="1">2</branch0>
    </rec_AA>
    <b number="1">3</b>
    <c number="1">4</c>
    <rec_BB number="1">
      <branch0 number="1">5</branch0>
      <rec_BBB number="1">
        <branch0 number="1">6</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_BB number="2">
      <branch0 number="1">7</branch0>
      <rec_BBB number="1">
        <branch0 number="1">8</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_CCC number="1">
      <branch0 number="1">9</branch0>
      <b number="1">10</b>
    </rec_CCC>
    <rec_BB number="3">
      <branch0 number="1">11</branch0>
      <rec_BBB number="1">
        <branch0 number="1">12</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_BBB number="1">
      <branch0 number="1">13</branch0>
    </rec_BBB>
    <rec_BBB number="2">
      <branch0 number="1">14</branch0>
    </rec_BBB>
    <rec_BBB number="3">
      <branch0 number="1">15</branch0>
    </rec_BBB>
  </rec_A>
  <rec_A number="9">
    <branch0 number="1">1</branch0>
    <rec_AA number="1">
      <branch0 number="1">2</branch0>
    </rec_AA>
    <b number="1">3</b>
    <c number="1">4</c>
    <rec_BB number="1">
      <branch0 number="1">5</branch0>
      <rec_BBB number="1">
        <branch0 number="1">6</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_BB number="2">
      <branch0 number="1">7</branch0>
      <rec_BBB number="1">
        <branch0 number="1">8</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_CCC number="1">
      <branch0 number="1">9</branch0>
      <b number="1">10</b>
    </rec_CCC>
    <rec_BB number="3">
      <branch0 number="1">11</branch0>
      <rec_BBB number="1">
        <branch0 number="1">12</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_BBB number="1">
      <branch0 number="1">13</branch0>
    </rec_BBB>
    <rec_BBB number="2">
      <branch0 number="1">14</branch0>
    </rec_BBB>
    <rec_BBB number="3">
      <branch0 number="1">15</branch0>
    </rec_BBB>
    <rec_BBB number="4">
      <branch0 number="1">16</branch0>
    </rec_BBB>
  </rec_A>
  <rec_A number="10">
    <branch0 number="1">1</branch0>
    <rec_AA number="1">
      <branch0 number="1">2</branch0>
    </rec_AA>
    <b number="1">3</b>
    <c number="1">4</c>
    <rec_BB number="1">
      <branch0 number="1">5</branch0>
      <rec_BBB number="1">
        <branch0 number="1">6</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_BB number="2">
      <branch0 number="1">7</branch0>
      <rec_BBB number="1">
        <branch0 number="1">8</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_CCC number="1">
      <branch0 number="1">9</branch0>
      <b number="1">10</b>
    </rec_CCC>
    <rec_BB number="3">
      <branch0 number="1">11</branch0>
      <rec_BBB number="1">
        <branch0 number="1">12</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_BBB number="1">
      <branch0 number="1">13</branch0>
    </rec_BBB>
    <rec_BBB number="2">
      <branch0 number="1">14</branch0>
    </rec_BBB>
    <rec_BBB number="3">
      <branch0 number="1">15</branch0>
    </rec_BBB>
    <rec_BBB number="4">
      <branch0 number="1">16</branch0>
    </rec_BBB>
    <rec_BBB number="5">
      <branch0 number="1">17</branch0>
    </rec_BBB>
  </rec_A>
  <rec_A number="11">
    <branch0 number="1">1</branch0>
    <rec_AA number="1">
      <branch0 number="1">2</branch0>
    </rec_AA>
    <b number="1">3</b>
    <c number="1">4</c>
    <rec_BB number="1">
      <branch0 number="1">5</branch0>
      <rec_BBB number="1">
        <branch0 number="1">6</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_BB number="2">
      <branch0 number="1">7</branch0>
      <rec_BBB number="1">
        <branch0 number="1">8</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_CCC number="1">
      <branch0 number="1">9</branch0>
      <b number="1">10</b>
    </rec_CCC>
    <rec_BB number="3">
      <branch0 number="1">11</branch0>
      <rec_BBB number="1">
        <branch0 number="1">12</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_BBB number="1">
      <branch0 number="1">13</branch0>
    </rec_BBB>
    <rec_BBB number="2">
      <branch0 number="1">14</branch0>
    </rec_BBB>
    <rec_BBB number="3">
      <branch0 number="1">15</branch0>
    </rec_BBB>
    <rec_BBB number="4">
      <branch0 number="1">16</branch0>
    </rec_BBB>
    <rec_BBB number="5">
      <branch0 number="1">17</branch0>
    </rec_BBB>
    <rec_BBB number="6">
      <branch0 number="1">18</branch0>
    </rec_BBB>
  </rec_A>
  <rec_A number="12">
    <branch0 number="1">1</branch0>
    <rec_AA number="1">
      <branch0 number="1">2</branch0>
    </rec_AA>
    <b number="1">3</b>
    <c number="1">4</c>
    <rec_BB number="1">
      <branch0 number="1">5</branch0>
      <rec_BBB number="1">
        <branch0 number="1">6</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_BB number="2">
      <branch0 number="1">7</branch0>
      <rec_BBB number="1">
        <branch0 number="1">8</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_CCC number="1">
      <branch0 number="1">9</branch0>
      <b number="1">10</b>
    </rec_CCC>
    <rec_BB number="3">
      <branch0 number="1">11</branch0>
      <rec_BBB number="1">
        <branch0 number="1">12</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_BBB number="1">
      <branch0 number="1">13</branch0>
    </rec_BBB>
    <rec_BBB number="2">
      <branch0 number="1">14</branch0>
    </rec_BBB>
    <rec_BBB number="3">
      <branch0 number="1">15</branch0>
    </rec_BBB>
    <rec_BBB number="4">
      <branch0 number="1">16</branch0>
    </rec_BBB>
    <rec_BBB number="5">
      <branch0 number="1">17</branch0>
    </rec_BBB>
    <rec_BBB number="6">
      <branch0 number="1">18</branch0>
    </rec_BBB>
    <rec_BBB number="7">
      <branch0 number="1">19</branch0>
    </rec_BBB>
  </rec_A>
  <rec_A number="13">
    <branch0 number="1">1</branch0>
    <rec_AA number="1">
      <branch0 number="1">2</branch0>
    </rec_AA>
    <b number="1">3</b>
    <c number="1">4</c>
    <rec_BB number="1">
      <branch0 number="1">5</branch0>
      <rec_BBB number="1">
        <branch0 number="1">6</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_BB number="2">
      <branch0 number="1">7</branch0>
      <rec_BBB number="1">
        <branch0 number="1">8</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_CCC number="1">
      <branch0 number="1">9</branch0>
      <b number="1">10</b>
    </rec_CCC>
    <rec_BB number="3">
      <branch0 number="1">11</branch0>
      <rec_BBB number="1">
        <branch0 number="1">12</branch0>
      </rec_BBB>
    </rec_BB>
    <rec_BBB number="1">
      <branch0 number="1">13</branch0>
    </rec_BBB>
    <rec_BBB number="2">
      <branch0 number="1">14</branch0>
    </rec_BBB>
    <rec_BBB number="3">
      <branch0 number="1">15</branch0>
    </rec_BBB>
    <rec_BBB number="4">
      <branch0 number="1">16</branch0>
    </rec_BBB>
    <rec_BBB number="5">
      <branch0 number="1">17</branch0>
    </rec_BBB>
    <rec_BBB number="6">
      <branch0 number="1">18</branch0>
    </rec_BBB>
    <rec_BBB number="7">
      <branch0 number="1">19</branch0>
    </rec_BBB>
    <rec_BBB number="8">
      <branch0 number="1">20</branch0>
    </rec_BBB>
  </rec_A>
</multitree>

Goto:   Top of page.   Section "Environment".   Section "Summary".   Section "Test cases".