Skip to content

Commit 3c6fceb

Browse files
committed
Add Microdata test
1 parent 762165b commit 3c6fceb

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

test/test_ppx.ml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -303,6 +303,16 @@ let attribs = "ppx attribs", HtmlTests.make Html.[
303303
[[%html "<div aria-hidden=true></div>"]],
304304
[div ~a:[a_aria "hidden" ["true"]] []] ;
305305

306+
"microdata attributes",
307+
[[%html "<dl itemscope itemtype='https://md.example.com/track https://md.example.com/lighting'><dt>Name</dt><dd itemprop='name'>Turnout Lantern Kit</dd></dl>"]],
308+
[dl
309+
~a:[a_itemscope (); a_itemtype ["https://md.example.com/track"; "https://md.example.com/lighting"]]
310+
[
311+
dt [ txt "Name" ];
312+
dd ~a:[a_itemprop "name"] [ txt "Turnout Lantern Kit" ];
313+
]] ;
314+
315+
306316
"touch events",
307317
[[%html "<div ontouchstart='alert()'></div>"]],
308318
[div ~a:[a_ontouchstart "alert()"] []] ;

0 commit comments

Comments
 (0)