Skip to content

Commit 6fbd273

Browse files
committed
Chore: add some tests
1 parent 65a673a commit 6fbd273

9 files changed

+2975
-1
lines changed

test/fixtures/template-ast/svg-attrs-camel-case.ast.json

Lines changed: 1154 additions & 0 deletions
Large diffs are not rendered by default.
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
<template>
2+
<div>
3+
<svg viewBox="0 0 40 40"></svg>
4+
</div>
5+
</template>
6+
7+
<script>
8+
module.exports = {}
9+
</script>
Lines changed: 102 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,102 @@
1+
[
2+
[
3+
"Punctuator",
4+
"<"
5+
],
6+
[
7+
"VIdentifier",
8+
"template"
9+
],
10+
[
11+
"Punctuator",
12+
">"
13+
],
14+
[
15+
"VText",
16+
"\n "
17+
],
18+
[
19+
"Punctuator",
20+
"<"
21+
],
22+
[
23+
"VIdentifier",
24+
"div"
25+
],
26+
[
27+
"Punctuator",
28+
">"
29+
],
30+
[
31+
"VText",
32+
"\n "
33+
],
34+
[
35+
"Punctuator",
36+
"<"
37+
],
38+
[
39+
"VIdentifier",
40+
"svg"
41+
],
42+
[
43+
"VIdentifier",
44+
"viewBox"
45+
],
46+
[
47+
"Punctuator",
48+
"="
49+
],
50+
[
51+
"VAttributeValue",
52+
"\"0 0 40 40\""
53+
],
54+
[
55+
"Punctuator",
56+
">"
57+
],
58+
[
59+
"Punctuator",
60+
"</"
61+
],
62+
[
63+
"VIdentifier",
64+
"svg"
65+
],
66+
[
67+
"Punctuator",
68+
">"
69+
],
70+
[
71+
"VText",
72+
"\n "
73+
],
74+
[
75+
"Punctuator",
76+
"</"
77+
],
78+
[
79+
"VIdentifier",
80+
"div"
81+
],
82+
[
83+
"Punctuator",
84+
">"
85+
],
86+
[
87+
"VText",
88+
"\n"
89+
],
90+
[
91+
"Punctuator",
92+
"</"
93+
],
94+
[
95+
"VIdentifier",
96+
"template"
97+
],
98+
[
99+
"Punctuator",
100+
">"
101+
]
102+
]
Lines changed: 222 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,222 @@
1+
[
2+
[
3+
"enter",
4+
"VElement",
5+
"<template>\n <div>\n <svg viewBox=\"0 0 40 40\"></svg>\n </div>\n</template>"
6+
],
7+
[
8+
"enter",
9+
"VStartTag",
10+
"<template>"
11+
],
12+
[
13+
"enter",
14+
"VIdentifier",
15+
"template"
16+
],
17+
[
18+
"leave",
19+
"VIdentifier",
20+
"template"
21+
],
22+
[
23+
"leave",
24+
"VStartTag",
25+
"<template>"
26+
],
27+
[
28+
"enter",
29+
"VText",
30+
"\n "
31+
],
32+
[
33+
"leave",
34+
"VText",
35+
"\n "
36+
],
37+
[
38+
"enter",
39+
"VElement",
40+
"<div>\n <svg viewBox=\"0 0 40 40\"></svg>\n </div>"
41+
],
42+
[
43+
"enter",
44+
"VStartTag",
45+
"<div>"
46+
],
47+
[
48+
"enter",
49+
"VIdentifier",
50+
"div"
51+
],
52+
[
53+
"leave",
54+
"VIdentifier",
55+
"div"
56+
],
57+
[
58+
"leave",
59+
"VStartTag",
60+
"<div>"
61+
],
62+
[
63+
"enter",
64+
"VText",
65+
"\n "
66+
],
67+
[
68+
"leave",
69+
"VText",
70+
"\n "
71+
],
72+
[
73+
"enter",
74+
"VElement",
75+
"<svg viewBox=\"0 0 40 40\"></svg>"
76+
],
77+
[
78+
"enter",
79+
"VStartTag",
80+
"<svg viewBox=\"0 0 40 40\">"
81+
],
82+
[
83+
"enter",
84+
"VIdentifier",
85+
"svg"
86+
],
87+
[
88+
"leave",
89+
"VIdentifier",
90+
"svg"
91+
],
92+
[
93+
"enter",
94+
"VAttribute",
95+
"viewBox=\"0 0 40 40\""
96+
],
97+
[
98+
"enter",
99+
"VIdentifier",
100+
"viewBox"
101+
],
102+
[
103+
"leave",
104+
"VIdentifier",
105+
"viewBox"
106+
],
107+
[
108+
"enter",
109+
"VAttributeValue",
110+
"\"0 0 40 40\""
111+
],
112+
[
113+
"leave",
114+
"VAttributeValue",
115+
"\"0 0 40 40\""
116+
],
117+
[
118+
"leave",
119+
"VAttribute",
120+
"viewBox=\"0 0 40 40\""
121+
],
122+
[
123+
"leave",
124+
"VStartTag",
125+
"<svg viewBox=\"0 0 40 40\">"
126+
],
127+
[
128+
"enter",
129+
"VEndTag",
130+
"</svg>"
131+
],
132+
[
133+
"enter",
134+
"VIdentifier",
135+
"svg"
136+
],
137+
[
138+
"leave",
139+
"VIdentifier",
140+
"svg"
141+
],
142+
[
143+
"leave",
144+
"VEndTag",
145+
"</svg>"
146+
],
147+
[
148+
"leave",
149+
"VElement",
150+
"<svg viewBox=\"0 0 40 40\"></svg>"
151+
],
152+
[
153+
"enter",
154+
"VText",
155+
"\n "
156+
],
157+
[
158+
"leave",
159+
"VText",
160+
"\n "
161+
],
162+
[
163+
"enter",
164+
"VEndTag",
165+
"</div>"
166+
],
167+
[
168+
"enter",
169+
"VIdentifier",
170+
"div"
171+
],
172+
[
173+
"leave",
174+
"VIdentifier",
175+
"div"
176+
],
177+
[
178+
"leave",
179+
"VEndTag",
180+
"</div>"
181+
],
182+
[
183+
"leave",
184+
"VElement",
185+
"<div>\n <svg viewBox=\"0 0 40 40\"></svg>\n </div>"
186+
],
187+
[
188+
"enter",
189+
"VText",
190+
"\n"
191+
],
192+
[
193+
"leave",
194+
"VText",
195+
"\n"
196+
],
197+
[
198+
"enter",
199+
"VEndTag",
200+
"</template>"
201+
],
202+
[
203+
"enter",
204+
"VIdentifier",
205+
"template"
206+
],
207+
[
208+
"leave",
209+
"VIdentifier",
210+
"template"
211+
],
212+
[
213+
"leave",
214+
"VEndTag",
215+
"</template>"
216+
],
217+
[
218+
"leave",
219+
"VElement",
220+
"<template>\n <div>\n <svg viewBox=\"0 0 40 40\"></svg>\n </div>\n</template>"
221+
]
222+
]

0 commit comments

Comments
 (0)