Fri, 23 Apr 2021 21:18:24 +0100
Add lxp.totable by Tom?s Guisasola
37
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
1 | #!/usr/local/bin/lua |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
2 | |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
3 | local totable = require "lxp.totable" |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
4 | |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
5 | local tests = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
6 | { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
7 | [[<abc a1="A1" a2="A2">inside tag `abc'</abc>]], |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
8 | { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
9 | [0] = "abc", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
10 | a1 = "A1", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
11 | a2 = "A2", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
12 | "inside tag `abc'", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
13 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
14 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
15 | { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
16 | [[<qwerty q1="q1" q2="q2"> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
17 | <asdf>some text</asdf> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
18 | </qwerty>]], |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
19 | { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
20 | [0] = "qwerty", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
21 | q1 = "q1", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
22 | q2 = "q2", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
23 | "\n\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
24 | { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
25 | [0] = "asdf", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
26 | "some text", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
27 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
28 | "\n", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
29 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
30 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
31 | { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
32 | [[ |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
33 | <!-- http://www.w3schools.com/xml/simple.xml --> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
34 | <breakfast_menu> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
35 | <food> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
36 | <name>Belgian Waffles</name> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
37 | <price>$5.95</price> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
38 | <description>Two of our famous Belgian Waffles with plenty of real maple syrup</description> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
39 | <calories>650</calories> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
40 | </food> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
41 | <food> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
42 | <name>Strawberry Belgian Waffles</name> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
43 | <price>$7.95</price> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
44 | <description>Light Belgian waffles covered with strawberries and whipped cream</description> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
45 | <calories>900</calories> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
46 | </food> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
47 | <food> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
48 | <name>Berry-Berry Belgian Waffles</name> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
49 | <price>$8.95</price> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
50 | <description>Light Belgian waffles covered with an assortment of fresh berries and whipped cream</description> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
51 | <calories>900</calories> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
52 | </food> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
53 | <food> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
54 | <name>French Toast</name> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
55 | <price>$4.50</price> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
56 | <description>Thick slices made from our homemade sourdough bread</description> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
57 | <calories>600</calories> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
58 | </food> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
59 | <food> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
60 | <name>Homestyle Breakfast</name> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
61 | <price>$6.95</price> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
62 | <description>Two eggs, bacon or sausage, toast, and our ever-popular hash browns</description> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
63 | <calories>950</calories> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
64 | </food> |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
65 | </breakfast_menu>]], |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
66 | { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
67 | [0] = "breakfast_menu", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
68 | [1] = "\n\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
69 | [2] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
70 | [0] = "food", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
71 | [1] = "\n\t\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
72 | [2] = { [0] = "name", [1] = "Belgian Waffles", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
73 | [3] = "\n\t\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
74 | [4] = { [0] = "price", [1] = "$5.95", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
75 | [5] = "\n\t\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
76 | [6] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
77 | [0] = "description", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
78 | [1] = "Two of our famous Belgian Waffles with plenty of real maple syrup", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
79 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
80 | [7] = "\n\t\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
81 | [8] = { [0] = "calories", [1] = "650", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
82 | [9] = "\n\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
83 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
84 | [3] = "\n\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
85 | [4] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
86 | [0] = "food", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
87 | [1] = "\n\t\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
88 | [2] = { [0] = "name", [1] = "Strawberry Belgian Waffles", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
89 | [3] = "\n\t\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
90 | [4] = { [0] = "price", [1] = "$7.95", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
91 | [5] = "\n\t\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
92 | [6] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
93 | [0] = "description", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
94 | [1] = "Light Belgian waffles covered with strawberries and whipped cream", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
95 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
96 | [7] = "\n\t\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
97 | [8] = { [0] = "calories", [1] = "900", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
98 | [9] = "\n\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
99 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
100 | [5] = "\n\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
101 | [6] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
102 | [0] = "food", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
103 | [1] = "\n\t\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
104 | [2] = { [0] = "name", [1] = "Berry-Berry Belgian Waffles", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
105 | [3] = "\n\t\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
106 | [4] = { [0] = "price", [1] = "$8.95", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
107 | [5] = "\n\t\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
108 | [6] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
109 | [0] = "description", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
110 | [1] = "Light Belgian waffles covered with an assortment of fresh berries and whipped cream", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
111 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
112 | [7] = "\n\t\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
113 | [8] = { [0] = "calories", [1] = "900", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
114 | [9] = "\n\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
115 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
116 | [7] = "\n\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
117 | [8] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
118 | [0] = "food", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
119 | [1] = "\n\t\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
120 | [2] = { [0] = "name", [1] = "French Toast", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
121 | [3] = "\n\t\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
122 | [4] = { [0] = "price", [1] = "$4.50", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
123 | [5] = "\n\t\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
124 | [6] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
125 | [0] = "description", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
126 | [1] = "Thick slices made from our homemade sourdough bread", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
127 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
128 | [7] = "\n\t\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
129 | [8] = { [0] = "calories", [1] = "600", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
130 | [9] = "\n\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
131 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
132 | [9] = "\n\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
133 | [10] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
134 | [0] = "food", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
135 | [1] = "\n\t\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
136 | [2] = { [0] = "name", [1] = "Homestyle Breakfast", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
137 | [3] = "\n\t\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
138 | [4] = { [0] = "price", [1] = "$6.95", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
139 | [5] = "\n\t\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
140 | [6] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
141 | [0] = "description", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
142 | [1] = "Two eggs, bacon or sausage, toast, and our ever-popular hash browns", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
143 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
144 | [7] = "\n\t\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
145 | [8] = { [0] = "calories", [1] = "950", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
146 | [9] = "\n\t", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
147 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
148 | [11] = "\n", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
149 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
150 | clean = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
151 | [0] = "breakfast_menu", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
152 | [1] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
153 | [0] = "food", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
154 | [1] = { [0] = "name", [1] = "Belgian Waffles", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
155 | [2] = { [0] = "price", [1] = "$5.95", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
156 | [3] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
157 | [0] = "description", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
158 | [1] = "Two of our famous Belgian Waffles with plenty of real maple syrup", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
159 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
160 | [4] = { [0] = "calories", [1] = "650", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
161 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
162 | [2] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
163 | [0] = "food", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
164 | [1] = { [0] = "name", [1] = "Strawberry Belgian Waffles", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
165 | [2] = { [0] = "price", [1] = "$7.95", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
166 | [3] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
167 | [0] = "description", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
168 | [1] = "Light Belgian waffles covered with strawberries and whipped cream", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
169 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
170 | [4] = { [0] = "calories", [1] = "900", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
171 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
172 | [3] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
173 | [0] = "food", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
174 | [1] = { [0] = "name", [1] = "Berry-Berry Belgian Waffles", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
175 | [2] = { [0] = "price", [1] = "$8.95", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
176 | [3] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
177 | [0] = "description", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
178 | [1] = "Light Belgian waffles covered with an assortment of fresh berries and whipped cream", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
179 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
180 | [4] = { [0] = "calories", [1] = "900", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
181 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
182 | [4] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
183 | [0] = "food", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
184 | [1] = { [0] = "name", [1] = "French Toast", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
185 | [2] = { [0] = "price", [1] = "$4.50", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
186 | [3] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
187 | [0] = "description", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
188 | [1] = "Thick slices made from our homemade sourdough bread", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
189 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
190 | [4] = { [0] = "calories", [1] = "600", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
191 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
192 | [5] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
193 | [0] = "food", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
194 | [1] = { [0] = "name", [1] = "Homestyle Breakfast", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
195 | [2] = { [0] = "price", [1] = "$6.95", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
196 | [3] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
197 | [0] = "description", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
198 | [1] = "Two eggs, bacon or sausage, toast, and our ever-popular hash browns", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
199 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
200 | [4] = { [0] = "calories", [1] = "950", }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
201 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
202 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
203 | torecord = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
204 | [0] = "breakfast_menu", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
205 | [1] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
206 | [0] = "food", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
207 | name = "Belgian Waffles", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
208 | price = "$5.95", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
209 | description = "Two of our famous Belgian Waffles with plenty of real maple syrup", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
210 | calories = "650", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
211 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
212 | [2] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
213 | [0] = "food", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
214 | name = "Strawberry Belgian Waffles", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
215 | price = "$7.95", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
216 | description = "Light Belgian waffles covered with strawberries and whipped cream", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
217 | calories = "900", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
218 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
219 | [3] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
220 | [0] = "food", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
221 | name = "Berry-Berry Belgian Waffles", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
222 | price = "$8.95", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
223 | description = "Light Belgian waffles covered with an assortment of fresh berries and whipped cream", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
224 | calories = "900", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
225 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
226 | [4] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
227 | [0] = "food", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
228 | name = "French Toast", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
229 | price = "$4.50", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
230 | description = "Thick slices made from our homemade sourdough bread", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
231 | calories = "600", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
232 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
233 | [5] = { |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
234 | [0] = "food", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
235 | name = "Homestyle Breakfast", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
236 | price = "$6.95", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
237 | description = "Two eggs, bacon or sausage, toast, and our ever-popular hash browns", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
238 | calories = "950", |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
239 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
240 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
241 | }, |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
242 | } |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
243 | |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
244 | |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
245 | function table.equal (t1, t2) |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
246 | for nome, val in pairs (t1) do |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
247 | local tv = type(val) |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
248 | if tv == "table" then |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
249 | if type(t2[nome]) ~= "table" then |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
250 | return false, "Different types at entry `"..nome.."': t1."..nome.." is "..tv.." while t2."..nome.." is "..type(t2[nome]).." ["..tostring(t2[nome]).."]" |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
251 | else |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
252 | local ok, msg = table.equal (val, t2[nome]) |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
253 | if not ok then |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
254 | return false, "["..nome.."]\t"..tostring(val).." ~= "..tostring(t2[nome]).."; "..msg |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
255 | end |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
256 | end |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
257 | else |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
258 | if val ~= t2[nome] then |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
259 | return false, "["..nome.."]\t"..tostring(val).." ~= "..tostring(t2[nome]) |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
260 | end |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
261 | end |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
262 | end |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
263 | return true |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
264 | end |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
265 | |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
266 | |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
267 | for i, s in ipairs(tests) do |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
268 | local ds = assert (totable.parse ([[<?xml version="1.0" encoding="ISO-8859-1"?>]]..s[1])) |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
269 | assert(table.equal (ds, s[2])) |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
270 | end |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
271 | |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
272 | local t = totable.parse ([[<?xml version="1.0" encoding="ISO-8859-1"?>]]..tests[3][1]) |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
273 | totable.clean (t) |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
274 | assert (table.equal (t, tests[3].clean)) |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
275 | totable.torecord (t) |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
276 | assert (table.equal (t, tests[3].torecord)) |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
277 | |
233463804681
Add lxp.totable by Tom?s Guisasola
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
278 | print"OK" |