summaryrefslogtreecommitdiffstats
path: root/toolkit/components/microformats/test/standards-tests
diff options
context:
space:
mode:
Diffstat (limited to 'toolkit/components/microformats/test/standards-tests')
-rw-r--r--toolkit/components/microformats/test/standards-tests/index.html179
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-mixed-h-card-mixedpropertries.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-mixed-h-card-tworoots.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-mixed-h-entry-mixedroots.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-mixed-h-resume-mixedroots.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-adr-simpleproperties.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-geo-abbrpattern.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-geo-hidden.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-geo-simpleproperties.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-geo-valuetitleclass.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hcalendar-ampm.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hcalendar-attendees.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hcalendar-combining.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hcalendar-concatenate.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hcalendar-time.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hcard-email.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hcard-format.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hcard-hyperlinkedphoto.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hcard-justahyperlink.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hcard-justaname.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hcard-multiple.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hcard-name.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hcard-single.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hentry-summarycontent.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hfeed-simple.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hnews-all.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hnews-minimum.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hproduct-aggregate.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hproduct-simpleproperties.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hresume-affiliation.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hresume-contact.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hresume-education.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hresume-skill.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hresume-work.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hreview-aggregate-hcard.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hreview-aggregate-justahyperlink.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hreview-aggregate-vevent.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hreview-item.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-hreview-vcard.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-includes-hcarditemref.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-includes-heventitemref.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-includes-hyperlink.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-includes-object.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v1-includes-table.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-adr-geo.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-adr-geourl.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-adr-justaname.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-adr-simpleproperties.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-as-note-note.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-card-baseurl.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-card-childimplied.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-card-extendeddescription.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-card-hcard.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-card-horghcard.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-card-hyperlinkedphoto.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-card-impliedname.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-card-impliedphoto.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-card-impliedurl.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-card-justahyperlink.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-card-justaname.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-card-nested.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-card-p-property.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-card-relativeurls.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-entry-impliedvalue-nested.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-entry-justahyperlink.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-entry-justaname.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-entry-summarycontent.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-entry-u-property.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-entry-urlincontent.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-event-ampm.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-event-attendees.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-event-combining.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-event-concatenate.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-event-dates.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-event-dt-property.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-event-justahyperlink.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-event-justaname.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-event-time.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-feed-implied-title.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-feed-simple.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-geo-abbrpattern.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-geo-altitude.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-geo-hidden.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-geo-justaname.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-geo-simpleproperties.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-geo-valuetitleclass.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-news-all.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-news-minimum.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-org-hyperlink.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-org-simple.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-org-simpleproperties.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-product-aggregate.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-product-justahyperlink.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-product-justaname.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-product-simpleproperties.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-recipe-all.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-recipe-minimum.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-resume-affiliation.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-resume-contact.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-resume-education.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-resume-justaname.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-resume-skill.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-resume-work.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-review-aggregate-hevent.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-review-aggregate-justahyperlink.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-review-aggregate-simpleproperties.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-review-hyperlink.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-review-implieditem.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-review-item.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-review-justaname.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-review-photo.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-h-review-vcard.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-rel-duplicate-rels.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-rel-license.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-rel-nofollow.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-rel-rel-urls.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-rel-varying-text-duplicate-rels.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-rel-xfn-all.js27
-rw-r--r--toolkit/components/microformats/test/standards-tests/mf-v2-rel-xfn-elsewhere.js27
119 files changed, 3365 insertions, 0 deletions
diff --git a/toolkit/components/microformats/test/standards-tests/index.html b/toolkit/components/microformats/test/standards-tests/index.html
new file mode 100644
index 000000000..47f89f988
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/index.html
@@ -0,0 +1,179 @@
+<html><head><title>Mocha</title>
+<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
+<link rel="stylesheet" href="../static/css/mocha.css" />
+<script src="../static/javascript/chai.js"></script>
+<script src="../static/javascript/mocha.js"></script>
+<link rel="stylesheet" href="../static/css/mocha-custom.css" />
+<link rel="icon" type="image/png" id="favicon" href="chrome://branding/content/icon32.png"/>
+
+<script src="../static/javascript/DOMParser.js"></script>
+
+<script data-cover src="../../microformat-shiv.js"></script>
+
+<script>
+var uncaughtError;
+
+window.addEventListener("error", function(error) {
+uncaughtError = error;
+});
+
+var consoleWarn = console.warn;
+var caughtWarnings = [];
+
+console.warn = function() {
+var args = Array.slice(arguments);
+caughtWarnings.push(args);
+consoleWarn.apply(console, args);
+};
+</script>
+
+<script>
+chai.config.includeStack = true;
+mocha.setup({ui: 'bdd', timeout: 10000});
+</script>
+
+<script src="../standards-tests/mf-mixed-h-card-mixedpropertries.js"></script>
+<script src="../standards-tests/mf-mixed-h-card-tworoots.js"></script>
+<script src="../standards-tests/mf-mixed-h-entry-mixedroots.js"></script>
+<script src="../standards-tests/mf-mixed-h-resume-mixedroots.js"></script>
+<script src="../standards-tests/mf-v1-adr-simpleproperties.js"></script>
+<script src="../standards-tests/mf-v1-geo-abbrpattern.js"></script>
+<script src="../standards-tests/mf-v1-geo-hidden.js"></script>
+<script src="../standards-tests/mf-v1-geo-simpleproperties.js"></script>
+<script src="../standards-tests/mf-v1-geo-valuetitleclass.js"></script>
+<script src="../standards-tests/mf-v1-hcalendar-ampm.js"></script>
+<script src="../standards-tests/mf-v1-hcalendar-attendees.js"></script>
+<script src="../standards-tests/mf-v1-hcalendar-combining.js"></script>
+<script src="../standards-tests/mf-v1-hcalendar-concatenate.js"></script>
+<script src="../standards-tests/mf-v1-hcalendar-time.js"></script>
+<script src="../standards-tests/mf-v1-hcard-email.js"></script>
+<script src="../standards-tests/mf-v1-hcard-format.js"></script>
+<script src="../standards-tests/mf-v1-hcard-hyperlinkedphoto.js"></script>
+<script src="../standards-tests/mf-v1-hcard-justahyperlink.js"></script>
+<script src="../standards-tests/mf-v1-hcard-justaname.js"></script>
+<script src="../standards-tests/mf-v1-hcard-multiple.js"></script>
+<script src="../standards-tests/mf-v1-hcard-name.js"></script>
+<script src="../standards-tests/mf-v1-hcard-single.js"></script>
+<script src="../standards-tests/mf-v1-hentry-summarycontent.js"></script>
+<script src="../standards-tests/mf-v1-hfeed-simple.js"></script>
+<script src="../standards-tests/mf-v1-hnews-all.js"></script>
+<script src="../standards-tests/mf-v1-hnews-minimum.js"></script>
+<script src="../standards-tests/mf-v1-hproduct-aggregate.js"></script>
+<script src="../standards-tests/mf-v1-hproduct-simpleproperties.js"></script>
+<script src="../standards-tests/mf-v1-hresume-affiliation.js"></script>
+<script src="../standards-tests/mf-v1-hresume-contact.js"></script>
+<script src="../standards-tests/mf-v1-hresume-education.js"></script>
+<script src="../standards-tests/mf-v1-hresume-skill.js"></script>
+<script src="../standards-tests/mf-v1-hresume-work.js"></script>
+<script src="../standards-tests/mf-v1-hreview-item.js"></script>
+<script src="../standards-tests/mf-v1-hreview-vcard.js"></script>
+<script src="../standards-tests/mf-v1-hreview-aggregate-hcard.js"></script>
+<script src="../standards-tests/mf-v1-hreview-aggregate-justahyperlink.js"></script>
+<script src="../standards-tests/mf-v1-hreview-aggregate-vevent.js"></script>
+<script src="../standards-tests/mf-v1-includes-hcarditemref.js"></script>
+<script src="../standards-tests/mf-v1-includes-heventitemref.js"></script>
+<script src="../standards-tests/mf-v1-includes-hyperlink.js"></script>
+<script src="../standards-tests/mf-v1-includes-object.js"></script>
+<script src="../standards-tests/mf-v1-includes-table.js"></script>
+<script src="../standards-tests/mf-v2-h-adr-geo.js"></script>
+<script src="../standards-tests/mf-v2-h-adr-geourl.js"></script>
+<script src="../standards-tests/mf-v2-h-adr-justaname.js"></script>
+<script src="../standards-tests/mf-v2-h-adr-simpleproperties.js"></script>
+<script src="../standards-tests/mf-v2-h-as-note-note.js"></script>
+<script src="../standards-tests/mf-v2-h-card-baseurl.js"></script>
+<script src="../standards-tests/mf-v2-h-card-childimplied.js"></script>
+<script src="../standards-tests/mf-v2-h-card-extendeddescription.js"></script>
+<script src="../standards-tests/mf-v2-h-card-hcard.js"></script>
+<script src="../standards-tests/mf-v2-h-card-horghcard.js"></script>
+<script src="../standards-tests/mf-v2-h-card-hyperlinkedphoto.js"></script>
+<script src="../standards-tests/mf-v2-h-card-impliedname.js"></script>
+<script src="../standards-tests/mf-v2-h-card-impliedphoto.js"></script>
+<script src="../standards-tests/mf-v2-h-card-impliedurl.js"></script>
+<script src="../standards-tests/mf-v2-h-card-justahyperlink.js"></script>
+<script src="../standards-tests/mf-v2-h-card-justaname.js"></script>
+<script src="../standards-tests/mf-v2-h-card-nested.js"></script>
+<script src="../standards-tests/mf-v2-h-card-p-property.js"></script>
+<script src="../standards-tests/mf-v2-h-card-relativeurls.js"></script>
+<script src="../standards-tests/mf-v2-h-entry-impliedvalue-nested.js"></script>
+<script src="../standards-tests/mf-v2-h-entry-justahyperlink.js"></script>
+<script src="../standards-tests/mf-v2-h-entry-justaname.js"></script>
+<script src="../standards-tests/mf-v2-h-entry-summarycontent.js"></script>
+<script src="../standards-tests/mf-v2-h-entry-u-property.js"></script>
+<script src="../standards-tests/mf-v2-h-entry-urlincontent.js"></script>
+<script src="../standards-tests/mf-v2-h-event-ampm.js"></script>
+<script src="../standards-tests/mf-v2-h-event-attendees.js"></script>
+<script src="../standards-tests/mf-v2-h-event-combining.js"></script>
+<script src="../standards-tests/mf-v2-h-event-concatenate.js"></script>
+<script src="../standards-tests/mf-v2-h-event-dates.js"></script>
+<script src="../standards-tests/mf-v2-h-event-dt-property.js"></script>
+<script src="../standards-tests/mf-v2-h-event-justahyperlink.js"></script>
+<script src="../standards-tests/mf-v2-h-event-justaname.js"></script>
+<script src="../standards-tests/mf-v2-h-event-time.js"></script>
+<script src="../standards-tests/mf-v2-h-feed-implied-title.js"></script>
+<script src="../standards-tests/mf-v2-h-feed-simple.js"></script>
+<script src="../standards-tests/mf-v2-h-geo-abbrpattern.js"></script>
+<script src="../standards-tests/mf-v2-h-geo-altitude.js"></script>
+<script src="../standards-tests/mf-v2-h-geo-hidden.js"></script>
+<script src="../standards-tests/mf-v2-h-geo-justaname.js"></script>
+<script src="../standards-tests/mf-v2-h-geo-simpleproperties.js"></script>
+<script src="../standards-tests/mf-v2-h-geo-valuetitleclass.js"></script>
+<script src="../standards-tests/mf-v2-h-news-all.js"></script>
+<script src="../standards-tests/mf-v2-h-news-minimum.js"></script>
+<script src="../standards-tests/mf-v2-h-org-hyperlink.js"></script>
+<script src="../standards-tests/mf-v2-h-org-simple.js"></script>
+<script src="../standards-tests/mf-v2-h-org-simpleproperties.js"></script>
+<script src="../standards-tests/mf-v2-h-product-aggregate.js"></script>
+<script src="../standards-tests/mf-v2-h-product-justahyperlink.js"></script>
+<script src="../standards-tests/mf-v2-h-product-justaname.js"></script>
+<script src="../standards-tests/mf-v2-h-product-simpleproperties.js"></script>
+<script src="../standards-tests/mf-v2-h-recipe-all.js"></script>
+<script src="../standards-tests/mf-v2-h-recipe-minimum.js"></script>
+<script src="../standards-tests/mf-v2-h-resume-affiliation.js"></script>
+<script src="../standards-tests/mf-v2-h-resume-contact.js"></script>
+<script src="../standards-tests/mf-v2-h-resume-education.js"></script>
+<script src="../standards-tests/mf-v2-h-resume-justaname.js"></script>
+<script src="../standards-tests/mf-v2-h-resume-skill.js"></script>
+<script src="../standards-tests/mf-v2-h-resume-work.js"></script>
+<script src="../standards-tests/mf-v2-h-review-hyperlink.js"></script>
+<script src="../standards-tests/mf-v2-h-review-implieditem.js"></script>
+<script src="../standards-tests/mf-v2-h-review-item.js"></script>
+<script src="../standards-tests/mf-v2-h-review-justaname.js"></script>
+<script src="../standards-tests/mf-v2-h-review-photo.js"></script>
+<script src="../standards-tests/mf-v2-h-review-vcard.js"></script>
+<script src="../standards-tests/mf-v2-h-review-aggregate-hevent.js"></script>
+<script src="../standards-tests/mf-v2-h-review-aggregate-justahyperlink.js"></script>
+<script src="../standards-tests/mf-v2-h-review-aggregate-simpleproperties.js"></script>
+<script src="../standards-tests/mf-v2-rel-duplicate-rels.js"></script>
+<script src="../standards-tests/mf-v2-rel-license.js"></script>
+<script src="../standards-tests/mf-v2-rel-nofollow.js"></script>
+<script src="../standards-tests/mf-v2-rel-rel-urls.js"></script>
+<script src="../standards-tests/mf-v2-rel-varying-text-duplicate-rels.js"></script>
+<script src="../standards-tests/mf-v2-rel-xfn-all.js"></script>
+<script src="../standards-tests/mf-v2-rel-xfn-elsewhere.js"></script>
+</head><body>
+<h3 class="capitalize">Microformats-shiv: standards tests</h3>
+<p>Standards tests built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST). Downloaded from github repo: microformats/tests version v0.1.24</p>
+<div id="mocha"></div>
+</body>
+<script>
+describe("Uncaught Error Check", function() {
+it("should load the tests without errors", function() {
+chai.expect(uncaughtError && uncaughtError.message).to.be.undefined;
+});
+});
+
+describe("Unexpected Warnings Check", function() {
+it("should long only the warnings we expect", function() {
+chai.expect(caughtWarnings.length).to.eql(0);
+});
+});
+
+mocha.run(function () {
+var completeNode = document.createElement("p");
+completeNode.setAttribute("id", "complete");
+completeNode.appendChild(document.createTextNode("Complete"));
+document.getElementById("mocha").appendChild(completeNode);
+});
+
+</script>
+</body></html>
diff --git a/toolkit/components/microformats/test/standards-tests/mf-mixed-h-card-mixedpropertries.js b/toolkit/components/microformats/test/standards-tests/mf-mixed-h-card-mixedpropertries.js
new file mode 100644
index 000000000..db99dc92a
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-mixed-h-card-mixedpropertries.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-mixed/h-card/mixedpropertries
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-card', function() {
+ var htmlFragment = "<div class=\"h-card\">\n <p>\n <a class=\"p-name p-org u-url\" href=\"http://mozilla.org/\">Mozilla Foundation</a>\n <img class=\"logo\" src=\"../logo.jpg\"/>\n </p>\n <p class=\"adr\">\n <span class=\"street-address\">665 3rd St.</span> \n <span class=\"extended-address\">Suite 207</span> \n <span class=\"locality\">San Francisco</span>, \n <span class=\"region\">CA</span> \n <span class=\"postal-code\">94107</span> \n <span class=\"p-country-name\">U.S.A.</span> \n </p>\n</div>";
+ var expected = {"items":[{"type":["h-card"],"properties":{"name":["Mozilla Foundation"],"org":["Mozilla Foundation"],"url":["http://mozilla.org/"],"adr":[{"value":"665 3rd St. \n Suite 207 \n San Francisco, \n CA \n 94107 \n U.S.A.","type":["h-adr"],"properties":{"street-address":["665 3rd St."],"extended-address":["Suite 207"],"locality":["San Francisco"],"region":["CA"],"postal-code":["94107"]}}]}}],"rels":{},"rel-urls":{}};
+
+ it('mixedpropertries', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-mixed-h-card-tworoots.js b/toolkit/components/microformats/test/standards-tests/mf-mixed-h-card-tworoots.js
new file mode 100644
index 000000000..be43abcd8
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-mixed-h-card-tworoots.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-mixed/h-card/tworoots
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-card', function() {
+ var htmlFragment = "<p class=\"h-card vcard\">Frances Berriman</p>";
+ var expected = {"items":[{"type":["h-card"],"properties":{"name":["Frances Berriman"]}}],"rels":{},"rel-urls":{}};
+
+ it('tworoots', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-mixed-h-entry-mixedroots.js b/toolkit/components/microformats/test/standards-tests/mf-mixed-h-entry-mixedroots.js
new file mode 100644
index 000000000..705ffeebf
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-mixed-h-entry-mixedroots.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-mixed/h-entry/mixedroots
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-entry', function() {
+ var htmlFragment = "<!-- simplified version of http://aaronparecki.com/notes/2013/10/18/2/realtimeconf-mapattack -->\n<base href=\"http://aaronparecki.com/\" />\n\n<div class=\"h-entry\">\n <div class=\"h-card vcard author p-author\">\n <img class=\"photo logo u-photo u-logo\" src=\"https://aaronparecki.com/images/aaronpk.png\" alt=\"Aaron Parecki\"/>\n <a href=\"https://aaronparecki.com/\" rel=\"author\" class=\"u-url u-uid url\">aaronparecki.com</a>\n <a class=\"p-name fn value\" href=\"https://aaronparecki.com/\">Aaron Parecki</a>\n <a href=\"https://plus.google.com/117847912875913905493\" rel=\"author\" class=\"google-profile\">Aaron Parecki</a>\n </div>\n <div class=\"entry-content e-content p-name\">Did you play\n <a href=\"http://twitter.com/playmapattack\">@playmapattack</a>at\n <a href=\"/tag/realtimeconf\">#<span class=\"p-category\">realtimeconf</span></a>? Here is some more info about how we built it!\n <a href=\"http://pdx.esri.com/blog/2013/10/17/introducting-mapattack/\"><span class=\"protocol\">http://</span>pdx.esri.com/blog/2013/10/17/introducting-mapattack/</a>\n </div>\n</div>";
+ var expected = {"items":[{"type":["h-entry"],"properties":{"author":[{"value":"aaronparecki.com\n Aaron Parecki\n Aaron Parecki","type":["h-card"],"properties":{"photo":["https://aaronparecki.com/images/aaronpk.png"],"logo":["https://aaronparecki.com/images/aaronpk.png"],"url":["https://aaronparecki.com/"],"uid":["https://aaronparecki.com/"],"name":["Aaron Parecki"]}}],"content":[{"value":"Did you play\n @playmapattackat\n #realtimeconf? Here is some more info about how we built it!\n http://pdx.esri.com/blog/2013/10/17/introducting-mapattack/","html":"Did you play\n <a href=\"http://twitter.com/playmapattack\">@playmapattack</a>at\n <a href=\"http://aaronparecki.com/tag/realtimeconf\">#<span class=\"p-category\">realtimeconf</span></a>? Here is some more info about how we built it!\n <a href=\"http://pdx.esri.com/blog/2013/10/17/introducting-mapattack/\"><span class=\"protocol\">http://</span>pdx.esri.com/blog/2013/10/17/introducting-mapattack/</a>\n "}],"name":["Did you play\n @playmapattackat\n #realtimeconf? Here is some more info about how we built it!\n http://pdx.esri.com/blog/2013/10/17/introducting-mapattack/"],"category":["realtimeconf"]}}],"rels":{"author":["https://aaronparecki.com/","https://plus.google.com/117847912875913905493"]},"rel-urls":{"https://aaronparecki.com/":{"text":"aaronparecki.com","rels":["author"]},"https://plus.google.com/117847912875913905493":{"text":"Aaron Parecki","rels":["author"]}}};
+
+ it('mixedroots', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-mixed-h-resume-mixedroots.js b/toolkit/components/microformats/test/standards-tests/mf-mixed-h-resume-mixedroots.js
new file mode 100644
index 000000000..5147866c6
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-mixed-h-resume-mixedroots.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-mixed/h-resume/mixedroots
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-resume', function() {
+ var htmlFragment = "<meta charset=\"utf-8\">\n<div class=\"h-resume\">\n <div class=\"p-contact vcard\">\n <p class=\"fn\">Tim Berners-Lee</p>\n <p class=\"title\">Director of the World Wide Web Foundation</p>\n </div>\n <p class=\"p-summary\">Invented the World Wide Web.</p><hr />\n <div class=\"p-experience vevent vcard\">\n <p class=\"title\">Director</p>\n <p><a class=\"fn org summary url\" href=\"http://www.webfoundation.org/\">World Wide Web Foundation</a></p>\n <p>\n <time class=\"dtstart\" datetime=\"2009-01-18\">Jan 2009</time> – Present\n <time class=\"duration\" datetime=\"P2Y11M\">(2 years 11 month)</time>\n </p>\n </div>\n</div>";
+ var expected = {"items":[{"type":["h-resume"],"properties":{"contact":[{"value":"Tim Berners-Lee","type":["h-card"],"properties":{"name":["Tim Berners-Lee"],"job-title":["Director of the World Wide Web Foundation"]}}],"summary":["Invented the World Wide Web."],"experience":[{"value":"World Wide Web Foundation","type":["h-event","h-card"],"properties":{"job-title":["Director"],"name":["World Wide Web Foundation"],"org":["World Wide Web Foundation"],"url":["http://www.webfoundation.org/"],"start":["2009-01-18"],"duration":["P2Y11M"]}}],"name":["Tim Berners-Lee\n Director of the World Wide Web Foundation\n \n Invented the World Wide Web.\n \n Director\n World Wide Web Foundation\n \n Jan 2009 – Present\n (2 years 11 month)"]}}],"rels":{},"rel-urls":{}};
+
+ it('mixedroots', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-adr-simpleproperties.js b/toolkit/components/microformats/test/standards-tests/mf-v1-adr-simpleproperties.js
new file mode 100644
index 000000000..09a346e0c
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-adr-simpleproperties.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/adr/simpleproperties
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('adr', function() {
+ var htmlFragment = "<p class=\"adr\">\n <span class=\"street-address\">665 3rd St.</span> \n <span class=\"extended-address\">Suite 207</span> \n <span class=\"locality\">San Francisco</span>, \n <span class=\"region\">CA</span> \n <span class=\"postal-code\">94107</span> \n <span class=\"country-name\">U.S.A.</span> \n</p>";
+ var expected = {"items":[{"type":["h-adr"],"properties":{"street-address":["665 3rd St."],"extended-address":["Suite 207"],"locality":["San Francisco"],"region":["CA"],"postal-code":["94107"],"country-name":["U.S.A."]}}],"rels":{},"rel-urls":{}};
+
+ it('simpleproperties', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-geo-abbrpattern.js b/toolkit/components/microformats/test/standards-tests/mf-v1-geo-abbrpattern.js
new file mode 100644
index 000000000..090e98bb9
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-geo-abbrpattern.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/geo/abbrpattern
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('geo', function() {
+ var htmlFragment = "<meta charset=\"utf-8\">\n<p class=\"geo\">\n <abbr class=\"latitude\" title=\"37.408183\">N 37° 24.491</abbr>, \n <abbr class=\"longitude\" title=\"-122.13855\">W 122° 08.313</abbr>\n</p>";
+ var expected = {"items":[{"type":["h-geo"],"properties":{"latitude":["37.408183"],"longitude":["-122.13855"]}}],"rels":{},"rel-urls":{}};
+
+ it('abbrpattern', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-geo-hidden.js b/toolkit/components/microformats/test/standards-tests/mf-v1-geo-hidden.js
new file mode 100644
index 000000000..d67a03b4f
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-geo-hidden.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/geo/hidden
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('geo', function() {
+ var htmlFragment = "<p>\n <span class=\"geo\">The Bricklayer's Arms\n <span class=\"latitude\">\n <span class=\"value-title\" title=\"51.513458\"> </span> \n </span>\n <span class=\"longitude\">\n <span class=\"value-title\" title=\"-0.14812\"> </span>\n </span>\n </span>\n</p>";
+ var expected = {"items":[{"type":["h-geo"],"properties":{"latitude":["51.513458"],"longitude":["-0.14812"]}}],"rels":{},"rel-urls":{}};
+
+ it('hidden', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-geo-simpleproperties.js b/toolkit/components/microformats/test/standards-tests/mf-v1-geo-simpleproperties.js
new file mode 100644
index 000000000..82cd7d3d9
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-geo-simpleproperties.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/geo/simpleproperties
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('geo', function() {
+ var htmlFragment = "We are meeting at \n<span class=\"geo\"> \n <span>The Bricklayer's Arms</span>\n (Geo: <span class=\"latitude\">51.513458</span>:\n <span class=\"longitude\">-0.14812</span>)\n</span>";
+ var expected = {"items":[{"type":["h-geo"],"properties":{"latitude":["51.513458"],"longitude":["-0.14812"]}}],"rels":{},"rel-urls":{}};
+
+ it('simpleproperties', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-geo-valuetitleclass.js b/toolkit/components/microformats/test/standards-tests/mf-v1-geo-valuetitleclass.js
new file mode 100644
index 000000000..196e07f7d
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-geo-valuetitleclass.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/geo/valuetitleclass
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('geo', function() {
+ var htmlFragment = "<meta charset=\"utf-8\">\n<p>\n <span class=\"geo\">\n <span class=\"latitude\">\n <span class=\"value-title\" title=\"51.513458\">N 51° 51.345</span>, \n </span>\n <span class=\"longitude\">\n <span class=\"value-title\" title=\"-0.14812\">W -0° 14.812</span>\n </span>\n </span>\n</p>";
+ var expected = {"items":[{"type":["h-geo"],"properties":{"latitude":["51.513458"],"longitude":["-0.14812"]}}],"rels":{},"rel-urls":{}};
+
+ it('valuetitleclass', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hcalendar-ampm.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hcalendar-ampm.js
new file mode 100644
index 000000000..5da5fd7df
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hcalendar-ampm.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hcalendar/ampm
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hcalendar', function() {
+ var htmlFragment = "<div class=\"vevent\">\n <span class=\"summary\">The 4th Microformat party</span> will be on \n <ul>\n <li class=\"dtstart\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <span class=\"value\">07:00:00pm \n </span></li>\n <li class=\"dtstart\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <span class=\"value\">07:00:00am \n </span></li>\n <li class=\"dtstart\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <span class=\"value\">07:00pm \n </span></li>\n <li class=\"dtstart\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <span class=\"value\">07pm \n </span></li>\n <li class=\"dtstart\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <span class=\"value\">7pm \n </span></li>\n <li class=\"dtstart\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <span class=\"value\">7:00pm \n </span></li>\n <li class=\"dtstart\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <span class=\"value\">07:00p.m. \n </span></li>\n <li class=\"dtstart\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <span class=\"value\">07:00PM \n </span></li>\n <li class=\"dtstart\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <span class=\"value\">7:00am \n </span></li>\n </ul>\n</div>";
+ var expected = {"items":[{"type":["h-event"],"properties":{"name":["The 4th Microformat party"],"start":["2009-06-26 19:00:00","2009-06-26 07:00:00","2009-06-26 19:00","2009-06-26 19","2009-06-26 19","2009-06-26 19:00","2009-06-26 19:00","2009-06-26 19:00","2009-06-26 07:00"]}}],"rels":{},"rel-urls":{}};
+
+ it('ampm', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hcalendar-attendees.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hcalendar-attendees.js
new file mode 100644
index 000000000..ca28ad431
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hcalendar-attendees.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hcalendar/attendees
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hcalendar', function() {
+ var htmlFragment = "<meta charset=\"utf-8\">\n<div class=\"vevent\">\n <span class=\"summary\">CPJ Online Press Freedom Summit</span>\n (<time class=\"dtstart\" datetime=\"2012-10-10\">10 Nov 2012</time>) in\n <span class=\"location\">San Francisco</span>.\n Attendees:\n <ul>\n <li class=\"attendee vcard\"><span class=\"fn\">Brian Warner</span></li>\n <li class=\"attendee vcard\"><span class=\"fn\">Kyle Machulis</span></li>\n <li class=\"attendee vcard\"><span class=\"fn\">Tantek Çelik</span></li>\n <li class=\"attendee vcard\"><span class=\"fn\">Sid Sutter</span></li>\n </ul>\n</div>\n";
+ var expected = {"items":[{"type":["h-event"],"properties":{"name":["CPJ Online Press Freedom Summit"],"start":["2012-10-10"],"location":["San Francisco"],"attendee":[{"value":"Brian Warner","type":["h-card"],"properties":{"name":["Brian Warner"]}},{"value":"Kyle Machulis","type":["h-card"],"properties":{"name":["Kyle Machulis"]}},{"value":"Tantek Çelik","type":["h-card"],"properties":{"name":["Tantek Çelik"]}},{"value":"Sid Sutter","type":["h-card"],"properties":{"name":["Sid Sutter"]}}]}}],"rels":{},"rel-urls":{}};
+
+ it('attendees', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hcalendar-combining.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hcalendar-combining.js
new file mode 100644
index 000000000..7e5a361b1
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hcalendar-combining.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hcalendar/combining
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hcalendar', function() {
+ var htmlFragment = "<div class=\"vevent\">\n <a class=\"summary url\" href=\"http://indiewebcamp.com/2012\">\n IndieWebCamp 2012\n </a>\n from <time class=\"dtstart\">2012-06-30</time> \n to <time class=\"dtend\">2012-07-01</time> at \n <span class=\"location vcard\">\n <a class=\"fn org url\" href=\"http://geoloqi.com/\">Geoloqi</a>, \n <span class=\"adr\">\n <span class=\"street-address\">920 SW 3rd Ave. Suite 400</span>, \n <span class=\"locality\">Portland</span>, \n <abbr class=\"region\" title=\"Oregon\">OR</abbr>\n </span>\n </span>\n</div>";
+ var expected = {"items":[{"type":["h-event"],"properties":{"name":["IndieWebCamp 2012"],"url":["http://indiewebcamp.com/2012"],"start":["2012-06-30"],"end":["2012-07-01"],"location":[{"value":"Geoloqi","type":["h-card"],"properties":{"name":["Geoloqi"],"org":["Geoloqi"],"url":["http://geoloqi.com/"],"adr":[{"value":"920 SW 3rd Ave. Suite 400, \n Portland, \n OR","type":["h-adr"],"properties":{"street-address":["920 SW 3rd Ave. Suite 400"],"locality":["Portland"],"region":["Oregon"]}}]}}]}}],"rels":{},"rel-urls":{}};
+
+ it('combining', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hcalendar-concatenate.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hcalendar-concatenate.js
new file mode 100644
index 000000000..d17914e1c
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hcalendar-concatenate.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hcalendar/concatenate
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hcalendar', function() {
+ var htmlFragment = "<div class=\"vevent\">\n <span class=\"summary\">The 4th Microformat party</span> will be on \n <span class=\"dtstart\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <time class=\"value\">19:00</time></span> to \n <span class=\"dtend\"><time class=\"value\">22:00</time></span>.\n</div>";
+ var expected = {"items":[{"type":["h-event"],"properties":{"name":["The 4th Microformat party"],"start":["2009-06-26 19:00"],"end":["2009-06-26 22:00"]}}],"rels":{},"rel-urls":{}};
+
+ it('concatenate', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hcalendar-time.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hcalendar-time.js
new file mode 100644
index 000000000..edb26d6ad
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hcalendar-time.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hcalendar/time
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hcalendar', function() {
+ var htmlFragment = "<div class=\"vevent\">\n <span class=\"summary\">The 4th Microformat party</span> will be on \n <ul>\n <li class=\"dtstart\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <time class=\"value\">19:00:00-08:00</time> \n </li>\n <li class=\"dtstart\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <time class=\"value\">19:00:00-0800</time> \n </li>\n <li class=\"dtstart\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <time class=\"value\">19:00:00+0800</time> \n </li> \n <li class=\"dtstart\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <time class=\"value\">19:00:00Z</time> \n </li>\n <li class=\"dtstart\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <time class=\"value\">19:00:00</time> \n </li>\n <li class=\"dtstart\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <time class=\"value\">19:00-08:00</time> \n </li> \n <li class=\"dtstart\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <time class=\"value\">19:00+08:00</time> \n </li>\n <li class=\"dtstart\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <time class=\"value\">19:00z</time> \n </li>\n <li class=\"dtstart\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <time class=\"value\">19:00</time> \n </li> \n <li>\n <time class=\"dtend\" datetime=\"2013-034\">3 February 2013</time>\n </li> \n </ul>\n</div>";
+ var expected = {"items":[{"type":["h-event"],"properties":{"name":["The 4th Microformat party"],"start":["2009-06-26 19:00:00-08:00","2009-06-26 19:00:00-08:00","2009-06-26 19:00:00+08:00","2009-06-26 19:00:00Z","2009-06-26 19:00:00","2009-06-26 19:00-08:00","2009-06-26 19:00+08:00","2009-06-26 19:00Z","2009-06-26 19:00"],"end":["2013-034"]}}],"rels":{},"rel-urls":{}};
+
+ it('time', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hcard-email.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hcard-email.js
new file mode 100644
index 000000000..48660ffb1
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hcard-email.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hcard/email
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hcard', function() {
+ var htmlFragment = "<div class=\"vcard\">\n <span class=\"fn\">John Doe</span> \n <ul>\n <li><a class=\"email\" href=\"mailto:john@example.com\">notthis@example.com</a></li>\n <li>\n <span class=\"email\">\n <span class=\"type\">internet</span> \n <a class=\"value\" href=\"mailto:john@example.com\">notthis@example.com</a>\n </span>\n </li> \n <li><a class=\"email\" href=\"mailto:john@example.com?subject=parser-test\">notthis@example.com</a></li>\n <li class=\"email\">john@example.com</li>\n </ul>\n</div>";
+ var expected = {"items":[{"type":["h-card"],"properties":{"name":["John Doe"],"email":["mailto:john@example.com","mailto:john@example.com","mailto:john@example.com?subject=parser-test","john@example.com"]}}],"rels":{},"rel-urls":{}};
+
+ it('email', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hcard-format.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hcard-format.js
new file mode 100644
index 000000000..eb539fd87
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hcard-format.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hcard/format
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hcard', function() {
+ var htmlFragment = "<p class=\"vcard\">\n <span class=\"profile-name fn n\">\n <span class=\" given-name \">John</span> \n <span class=\"FAMILY-NAME\">Doe</span> \n </span>\n</p>";
+ var expected = {"items":[{"type":["h-card"],"properties":{"name":["John \n Doe"],"given-name":["John"]}}],"rels":{},"rel-urls":{}};
+
+ it('format', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hcard-hyperlinkedphoto.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hcard-hyperlinkedphoto.js
new file mode 100644
index 000000000..7f348b4a8
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hcard-hyperlinkedphoto.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hcard/hyperlinkedphoto
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hcard', function() {
+ var htmlFragment = "<a class=\"vcard\" href=\"http://rohit.khare.org/\">\n <img alt=\"Rohit Khare\" src=\"images/photo.gif\" />\n</a>";
+ var expected = {"items":[{"type":["h-card"],"properties":{}}],"rels":{},"rel-urls":{}};
+
+ it('hyperlinkedphoto', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hcard-justahyperlink.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hcard-justahyperlink.js
new file mode 100644
index 000000000..e320f0f8a
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hcard-justahyperlink.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hcard/justahyperlink
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hcard', function() {
+ var htmlFragment = "<a class=\"vcard\" href=\"http://benward.me/\">Ben Ward</a>";
+ var expected = {"items":[{"type":["h-card"],"properties":{}}],"rels":{},"rel-urls":{}};
+
+ it('justahyperlink', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hcard-justaname.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hcard-justaname.js
new file mode 100644
index 000000000..ba2a6d47d
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hcard-justaname.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hcard/justaname
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hcard', function() {
+ var htmlFragment = "<p class=\"vcard\">Frances Berriman</p>";
+ var expected = {"items":[{"type":["h-card"],"properties":{}}],"rels":{},"rel-urls":{}};
+
+ it('justaname', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hcard-multiple.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hcard-multiple.js
new file mode 100644
index 000000000..058e5e2ae
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hcard-multiple.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hcard/multiple
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hcard', function() {
+ var htmlFragment = "<base href=\"http://example.com\">\n <div class=\"vcard\">\n \n <div class=\"fn n\"><span class=\"given-name\">John</span> <span class=\"family-name\">Doe</span></div>\n <a class=\"sound\" href=\"http://www.madgex.com/johndoe.mpeg\">Pronunciation of my name</a>\n <div><img class=\"photo\" src=\"images/photo.gif\" alt=\"Photo of John Doe\" /></div>\n\n <p>Nicknames:</p>\n <ul>\n <li class=\"nickname\">Man with no name</li>\n <li class=\"nickname\">Lost boy</li>\n </ul>\n\n <p>About:</p>\n <p class=\"note\">John Doe is one of those names you always have issues with.</p>\n <p class=\"note\">It can be a real problem booking a hotel room with the name John Doe.</p>\n\n <p>Companies:</p>\n <div>\n <img class=\"logo\" src=\"images/logo.gif\" alt=\"Madgex company logo\" />\n <img class=\"logo\" src=\"images/logo.gif\" alt=\"Web Feet Media company logo\" />\n </div>\n <ul>\n <li><a class=\"url org\" href=\"http://www.madgex.com/\">Madgex</a> <span class=\"title\">Creative Director</span></li>\n <li><a class=\"url org\" href=\"http://www.webfeetmedia.com/\">Web Feet Media Ltd</a> <span class=\"title\">Owner</span></li>\n </ul>\n \n <p>Tags: \n <a rel=\"tag\" class=\"category\" href=\"http://en.wikipedia.org/wiki/design\">design</a>, \n <a rel=\"tag\" class=\"category\" href=\"http://en.wikipedia.org/wiki/development\">development</a> and\n <a rel=\"tag\" class=\"category\" href=\"http://en.wikipedia.org/wiki/web\">web</a>\n </p>\n \n <p>Phone numbers:</p>\n <ul>\n <li class=\"tel\">\n <span class=\"type\">Work</span> (<span class=\"type\">pref</span>erred):\n <span class=\"value\">+1 415 555 100</span>\n </li>\n <li class=\"tel\"><span class=\"type\">Home</span>: <span class=\"value\">+1 415 555 200</span></li>\n <li class=\"tel\"><span class=\"type\">Postal</span>: <span class=\"value\">+1 415 555 300</span></li>\n </ul>\n \n <p>Emails:</p>\n <ul>\n <li><a class=\"email\" href=\"mailto:john.doe@madgex.com\">John Doe at Madgex</a></li>\n <li><a class=\"email\" href=\"mailto:john.doe@webfeetmedia.com\">John Doe at Web Feet Media</a></li>\n </ul>\n <p>John Doe uses <span class=\"mailer\">PigeonMail 2.1</span> or <span class=\"mailer\">Outlook 2007</span> for email.</p>\n\n <p>Addresses:</p>\n <ul>\n <li class=\"label\">\n <span class=\"adr\">\n <span class=\"type\">Work</span>: \n <span class=\"street-address\">North Street</span>, \n <span class=\"locality\">Brighton</span>, \n <span class=\"country-name\">United Kingdom</span>\n </span>\n \n </li>\n <li class=\"label\">\n <span class=\"adr\">\n <span class=\"type\">Home</span>: \n <span class=\"street-address\">West Street</span>, \n <span class=\"locality\">Brighton</span>, \n <span class=\"country-name\">United Kingdom</span>\n </span>\n </li>\n </ul>\n \n <p>In emergency contact: <span class=\"agent\">Jane Doe</span> or <span class=\"agent vcard\"><span class=\"fn\">Dave Doe</span></span>.</p>\n <p>Key: <span class=\"key\">hd02$Gfu*d%dh87KTa2=23934532479</span></p>\n</div>";
+ var expected = {"items":[{"type":["h-card"],"properties":{"name":["John Doe"],"given-name":["John"],"family-name":["Doe"],"sound":["http://www.madgex.com/johndoe.mpeg"],"photo":["http://example.com/images/photo.gif"],"nickname":["Man with no name","Lost boy"],"note":["John Doe is one of those names you always have issues with.","It can be a real problem booking a hotel room with the name John Doe."],"logo":["http://example.com/images/logo.gif","http://example.com/images/logo.gif"],"url":["http://www.madgex.com/","http://www.webfeetmedia.com/"],"org":["Madgex","Web Feet Media Ltd"],"job-title":["Creative Director","Owner"],"category":["design","development","web"],"tel":["+1 415 555 100","+1 415 555 200","+1 415 555 300"],"email":["mailto:john.doe@madgex.com","mailto:john.doe@webfeetmedia.com"],"mailer":["PigeonMail 2.1","Outlook 2007"],"label":["Work: \n North Street, \n Brighton, \n United Kingdom","Home: \n West Street, \n Brighton, \n United Kingdom"],"adr":[{"value":"Work: \n North Street, \n Brighton, \n United Kingdom","type":["h-adr"],"properties":{"street-address":["North Street"],"locality":["Brighton"],"country-name":["United Kingdom"]}},{"value":"Home: \n West Street, \n Brighton, \n United Kingdom","type":["h-adr"],"properties":{"street-address":["West Street"],"locality":["Brighton"],"country-name":["United Kingdom"]}}],"agent":["Jane Doe",{"value":"Dave Doe","type":["h-card"],"properties":{"name":["Dave Doe"]}}],"key":["hd02$Gfu*d%dh87KTa2=23934532479"]}}],"rels":{"tag":["http://en.wikipedia.org/wiki/design","http://en.wikipedia.org/wiki/development","http://en.wikipedia.org/wiki/web"]},"rel-urls":{"http://en.wikipedia.org/wiki/design":{"text":"design","rels":["tag"]},"http://en.wikipedia.org/wiki/development":{"text":"development","rels":["tag"]},"http://en.wikipedia.org/wiki/web":{"text":"web","rels":["tag"]}}};
+
+ it('multiple', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hcard-name.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hcard-name.js
new file mode 100644
index 000000000..ef75899cf
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hcard-name.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hcard/name
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hcard', function() {
+ var htmlFragment = "<base href=\"http://example.com\">\n<div class=\"vcard\">\n <div class=\"name\">\n <span class=\"honorific-prefix\">Dr</span> \n <span class=\"given-name\">John</span> \n <abbr class=\"additional-name\" title=\"Peter\">P</abbr> \n <span class=\"family-name\">Doe</span> \n <data class=\"honorific-suffix\" value=\"MSc\"></data>\n <img class=\"photo honorific-suffix\" src=\"images/logo.gif\" alt=\"PHD\" />\n </div>\n</div>";
+ var expected = {"items":[{"type":["h-card"],"properties":{"honorific-prefix":["Dr"],"given-name":["John"],"additional-name":["Peter"],"family-name":["Doe"],"honorific-suffix":["MSc","PHD"],"photo":["http://example.com/images/logo.gif"]}}],"rels":{},"rel-urls":{}};
+
+ it('name', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hcard-single.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hcard-single.js
new file mode 100644
index 000000000..a7ef7628b
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hcard-single.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hcard/single
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hcard', function() {
+ var htmlFragment = "<div class=\"vcard\">\n \n <div class=\"fn n\"><span class=\"given-name sort-string\">John</span> Doe</div>\n <div>Birthday: <abbr class=\"bday\" title=\"2000-01-01T00:00:00-08:00\">January 1st, 2000</abbr></div>\n <div>Role: <span class=\"role\">Designer</span></div>\n <div>Location: <abbr class=\"geo\" title=\"30.267991;-97.739568\">Brighton</abbr></div>\n <div>Time zone: <abbr class=\"tz\" title=\"-05:00\">Eastern Standard Time</abbr></div>\n \n <div>Profile details:\n <div>Profile id: <span class=\"uid\">http://example.com/profiles/johndoe</span></div>\n <div>Details are: <span class=\"class\">Public</span></div>\n <div>Last updated: <abbr class=\"rev\" title=\"2008-01-01T13:45:00\">January 1st, 2008 - 13:45</abbr></div>\n </div>\n </div>";
+ var expected = {"items":[{"type":["h-card"],"properties":{"name":["John Doe"],"given-name":["John"],"sort-string":["John"],"bday":["2000-01-01 00:00:00-08:00"],"role":["Designer"],"geo":[{"value":"30.267991;-97.739568","type":["h-geo"],"properties":{"name":["30.267991;-97.739568"]}}],"tz":["-05:00"],"uid":["http://example.com/profiles/johndoe"],"class":["Public"],"rev":["2008-01-01 13:45:00"]}}],"rels":{},"rel-urls":{}};
+
+ it('single', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hentry-summarycontent.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hentry-summarycontent.js
new file mode 100644
index 000000000..5280efb04
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hentry-summarycontent.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hentry/summarycontent
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hentry', function() {
+ var htmlFragment = "<meta charset=\"utf-8\">\n<div class=\"hentry\">\n <h1><a class=\"entry-title\" href=\"http://microformats.org/2012/06/25/microformats-org-at-7\">microformats.org at 7</a></h1>\n <div class=\"entry-content\">\n <p class=\"entry-summary\">Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities.</p>\n\n <p>The microformats tagline “humans first, machines second” \n forms the basis of many of our \n <a href=\"http://microformats.org/wiki/principles\">principles</a>, and \n in that regard, we’d like to recognize a few people and \n thank them for their years of volunteer service </p>\n </div> \n <p>Updated \n <time class=\"updated\" datetime=\"2012-06-25T17:08:26\">June 25th, 2012</time> by\n <span class=\"author vcard\"><a class=\"fn url\" href=\"http://tantek.com/\">Tantek</a></span>\n </p>\n</div>";
+ var expected = {"items":[{"type":["h-entry"],"properties":{"name":["microformats.org at 7"],"content":[{"value":"Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities.\n\n The microformats tagline “humans first, machines second” \n forms the basis of many of our \n principles, and \n in that regard, we’d like to recognize a few people and \n thank them for their years of volunteer service","html":"\n <p class=\"entry-summary\">Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities.</p>\n\n <p>The microformats tagline “humans first, machines second” \n forms the basis of many of our \n <a href=\"http://microformats.org/wiki/principles\">principles</a>, and \n in that regard, we’d like to recognize a few people and \n thank them for their years of volunteer service </p>\n "}],"summary":["Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities."],"updated":["2012-06-25 17:08:26"],"author":[{"value":"Tantek","type":["h-card"],"properties":{"name":["Tantek"],"url":["http://tantek.com/"]}}]}}],"rels":{},"rel-urls":{}};
+
+ it('summarycontent', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hfeed-simple.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hfeed-simple.js
new file mode 100644
index 000000000..4c8294d49
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hfeed-simple.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hfeed/simple
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hfeed', function() {
+ var htmlFragment = "<section class=\"hfeed\">\n\t<h1 class=\"name\">Microformats blog</h1>\n\t<span class=\"author vcard\"><a class=\"fn url\" href=\"http://tantek.com/\">Tantek</a></span>\n\t<a class=\"url\" href=\"http://microformats.org/blog\">permlink</a>\n\t<img class=\"photo\" src=\"photo.jpeg\"/>\n\t<p>\n\t\tTags: <a rel=\"tag\" href=\"tags/microformats\">microformats</a>, \n\t\t<a rel=\"tag\" href=\"tags/html\">html</a>\n\t</p>\n\t\n\t<div class=\"hentry\">\n\t <h1><a class=\"entry-title\" rel=\"bookmark\" href=\"http://microformats.org/2012/06/25/microformats-org-at-7\">microformats.org at 7</a></h1>\n\t <div class=\"entry-content\">\n\t <p class=\"entry-summary\">Last week the microformats.org community \n\t celebrated its 7th birthday at a gathering hosted by Mozilla in \n\t San Francisco and recognized accomplishments, challenges, and \n\t opportunities.</p>\n\t\n\t <p>The microformats tagline “humans first, machines second” \n\t forms the basis of many of our \n\t <a href=\"http://microformats.org/wiki/principles\">principles</a>, and \n\t in that regard, we’d like to recognize a few people and \n\t thank them for their years of volunteer service </p>\n\t </div> \n\t <p>Updated \n\t <time class=\"updated\" datetime=\"2012-06-25T17:08:26\">June 25th, 2012</time>\n\t </p>\n\t</div>\n\t\n</section>";
+ var expected = {"items":[{"type":["h-feed"],"properties":{"author":[{"value":"Tantek","type":["h-card"],"properties":{"name":["Tantek"],"url":["http://tantek.com/"]}}],"url":["http://microformats.org/blog"],"photo":["http://example.com/photo.jpeg"],"category":["microformats","html"]},"children":[{"value":"microformats.org at 7\n\t \n\t Last week the microformats.org community \n\t celebrated its 7th birthday at a gathering hosted by Mozilla in \n\t San Francisco and recognized accomplishments, challenges, and \n\t opportunities.\n\t\n\t The microformats tagline “humans first, machines second” \n\t forms the basis of many of our \n\t principles, and \n\t in that regard, we’d like to recognize a few people and \n\t thank them for their years of volunteer service \n\t \n\t Updated \n\t June 25th, 2012","type":["h-entry"],"properties":{"name":["microformats.org at 7"],"url":["http://microformats.org/2012/06/25/microformats-org-at-7"],"content":[{"value":"Last week the microformats.org community \n\t celebrated its 7th birthday at a gathering hosted by Mozilla in \n\t San Francisco and recognized accomplishments, challenges, and \n\t opportunities.\n\t\n\t The microformats tagline “humans first, machines second” \n\t forms the basis of many of our \n\t principles, and \n\t in that regard, we’d like to recognize a few people and \n\t thank them for their years of volunteer service","html":"\n\t <p class=\"entry-summary\">Last week the microformats.org community \n\t celebrated its 7th birthday at a gathering hosted by Mozilla in \n\t San Francisco and recognized accomplishments, challenges, and \n\t opportunities.</p>\n\t\n\t <p>The microformats tagline “humans first, machines second” \n\t forms the basis of many of our \n\t <a href=\"http://microformats.org/wiki/principles\">principles</a>, and \n\t in that regard, we’d like to recognize a few people and \n\t thank them for their years of volunteer service </p>\n\t "}],"summary":["Last week the microformats.org community \n\t celebrated its 7th birthday at a gathering hosted by Mozilla in \n\t San Francisco and recognized accomplishments, challenges, and \n\t opportunities."],"updated":["2012-06-25 17:08:26"]}}]}],"rels":{"tag":["http://example.com/tags/microformats","http://example.com/tags/html"],"bookmark":["http://microformats.org/2012/06/25/microformats-org-at-7"]},"rel-urls":{"http://example.com/tags/microformats":{"text":"microformats","rels":["tag"]},"http://example.com/tags/html":{"text":"html","rels":["tag"]},"http://microformats.org/2012/06/25/microformats-org-at-7":{"text":"microformats.org at 7","rels":["bookmark"]}}};
+
+ it('simple', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hnews-all.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hnews-all.js
new file mode 100644
index 000000000..82eb37b95
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hnews-all.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hnews/all
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hnews', function() {
+ var htmlFragment = "<div class=\"hnews\">\n <div class=\"entry hentry\">\n <h1><a class=\"entry-title\" rel=\"bookmark\" href=\"http://microformats.org/2012/06/25/microformats-org-at-7\">microformats.org at 7</a></h1>\n <div class=\"entry-content\">\n <p class=\"entry-summary\">Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities.</p>\n\n <p>The microformats tagline “humans first, machines second” \n forms the basis of many of our \n <a href=\"http://microformats.org/wiki/principles\">principles</a>, and \n in that regard, we’d like to recognize a few people and \n thank them for their years of volunteer service </p>\n </div> \n <p>Updated \n <time class=\"updated\" datetime=\"2012-06-25T17:08:26\">June 25th, 2012</time> by\n <span class=\"author vcard\"><a class=\"fn url\" href=\"http://tantek.com/\">Tantek</a></span>\n </p>\n </div>\n\n <p>\n <span class=\"dateline vcard\">\n <span class=\"adr\">\n <span class=\"locality\">San Francisco</span>, \n <span class=\"region\">CA</span> \n </span>\n </span>\n (Geo: <span class=\"geo\">37.774921;-122.445202</span>) \n <span class=\"source-org vcard\">\n <a class=\"fn org url\" href=\"http://microformats.org/\">microformats.org</a>\n </span>\n </p>\n <p>\n <a rel=\"principles\" href=\"http://microformats.org/wiki/Category:public_domain_license\">Publishing policy</a>\n </p>\n</div>";
+ var expected = {"items":[{"type":["h-news"],"properties":{"entry":[{"value":"microformats.org at 7","type":["h-entry"],"properties":{"name":["microformats.org at 7"],"url":["http://microformats.org/2012/06/25/microformats-org-at-7"],"content":[{"value":"Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities.\n\n The microformats tagline “humans first, machines second” \n forms the basis of many of our \n principles, and \n in that regard, we’d like to recognize a few people and \n thank them for their years of volunteer service","html":"\n <p class=\"entry-summary\">Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities.</p>\n\n <p>The microformats tagline “humans first, machines second” \n forms the basis of many of our \n <a href=\"http://microformats.org/wiki/principles\">principles</a>, and \n in that regard, we’d like to recognize a few people and \n thank them for their years of volunteer service </p>\n "}],"summary":["Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities."],"updated":["2012-06-25 17:08:26"],"author":[{"value":"Tantek","type":["h-card"],"properties":{"name":["Tantek"],"url":["http://tantek.com/"]}}]}}],"dateline":[{"value":"San Francisco, \n CA","type":["h-card"],"properties":{"adr":[{"value":"San Francisco, \n CA","type":["h-adr"],"properties":{"locality":["San Francisco"],"region":["CA"]}}]}}],"geo":[{"value":"37.774921;-122.445202","type":["h-geo"],"properties":{"name":["37.774921;-122.445202"]}}],"source-org":[{"value":"microformats.org","type":["h-card"],"properties":{"name":["microformats.org"],"org":["microformats.org"],"url":["http://microformats.org/"]}}],"principles":["http://microformats.org/wiki/Category:public_domain_license"]}}],"rels":{"bookmark":["http://microformats.org/2012/06/25/microformats-org-at-7"],"principles":["http://microformats.org/wiki/Category:public_domain_license"]},"rel-urls":{"http://microformats.org/2012/06/25/microformats-org-at-7":{"text":"microformats.org at 7","rels":["bookmark"]},"http://microformats.org/wiki/Category:public_domain_license":{"text":"Publishing policy","rels":["principles"]}}};
+
+ it('all', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hnews-minimum.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hnews-minimum.js
new file mode 100644
index 000000000..5faf13d7b
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hnews-minimum.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hnews/minimum
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hnews', function() {
+ var htmlFragment = "<div class=\"hnews\">\n <div class=\"entry hentry\">\n <h1><a class=\"entry-title\" rel=\"bookmark\" href=\"http://microformats.org/2012/06/25/microformats-org-at-7\">microformats.org at 7</a></h1>\n <div class=\"entry-content\">\n <p class=\"entry-summary\">Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities.</p>\n\n <p>The microformats tagline “humans first, machines second” \n forms the basis of many of our \n <a href=\"http://microformats.org/wiki/principles\">principles</a>, and \n in that regard, we’d like to recognize a few people and \n thank them for their years of volunteer service </p>\n </div> \n <p>Updated \n <time class=\"updated\" datetime=\"2012-06-25T17:08:26\">June 25th, 2012</time> by\n <span class=\"author vcard\"><a class=\"fn url\" href=\"http://tantek.com/\">Tantek</a></span>\n </p>\n </div>\n\n <p class=\"source-org vcard\">\n <a class=\"fn org url\" href=\"http://microformats.org/\">microformats.org</a> \n </p>\n</div>";
+ var expected = {"items":[{"type":["h-news"],"properties":{"entry":[{"value":"microformats.org at 7","type":["h-entry"],"properties":{"name":["microformats.org at 7"],"url":["http://microformats.org/2012/06/25/microformats-org-at-7"],"content":[{"value":"Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities.\n\n The microformats tagline “humans first, machines second” \n forms the basis of many of our \n principles, and \n in that regard, we’d like to recognize a few people and \n thank them for their years of volunteer service","html":"\n <p class=\"entry-summary\">Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities.</p>\n\n <p>The microformats tagline “humans first, machines second” \n forms the basis of many of our \n <a href=\"http://microformats.org/wiki/principles\">principles</a>, and \n in that regard, we’d like to recognize a few people and \n thank them for their years of volunteer service </p>\n "}],"summary":["Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities."],"updated":["2012-06-25 17:08:26"],"author":[{"value":"Tantek","type":["h-card"],"properties":{"name":["Tantek"],"url":["http://tantek.com/"]}}]}}],"source-org":[{"value":"microformats.org","type":["h-card"],"properties":{"name":["microformats.org"],"org":["microformats.org"],"url":["http://microformats.org/"]}}]}}],"rels":{"bookmark":["http://microformats.org/2012/06/25/microformats-org-at-7"]},"rel-urls":{"http://microformats.org/2012/06/25/microformats-org-at-7":{"text":"microformats.org at 7","rels":["bookmark"]}}};
+
+ it('minimum', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hproduct-aggregate.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hproduct-aggregate.js
new file mode 100644
index 000000000..7171bc726
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hproduct-aggregate.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hproduct/aggregate
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hproduct', function() {
+ var htmlFragment = "<meta charset=\"utf-8\">\n<div class=\"hproduct\">\n <h2 class=\"fn\">Raspberry Pi</h2>\n <img class=\"photo\" src=\"http://upload.wikimedia.org/wikipedia/commons/thumb/3/3d/RaspberryPi.jpg/320px-RaspberryPi.jpg\" />\n <p class=\"description\">The Raspberry Pi is a credit-card sized computer that plugs into your TV and a keyboard. It’s a capable little PC which can be used for many of the things that your desktop PC does, like spreadsheets, word-processing and games. It also plays high-definition video. We want to see it being used by kids all over the world to learn programming.</p>\n <a class=\"url\" href=\"http://www.raspberrypi.org/\">More info about the Raspberry Pi</a>\n <p class=\"price\">£29.95</p>\n <p class=\"review hreview-aggregate\">\n <span class=\"rating\">\n <span class=\"average value\">9.2</span> out of \n <span class=\"best\">10</span> \n based on <span class=\"count\">178</span> reviews\n </span>\n </p>\n <p>Categories: \n <a rel=\"tag\" href=\"http://en.wikipedia.org/wiki/computer\" class=\"category\">Computer</a>, \n <a rel=\"tag\" href=\"http://en.wikipedia.org/wiki/education\" class=\"category\">Education</a>\n </p>\n <p class=\"brand vcard\">From: \n <span class=\"fn org\">The Raspberry Pi Foundation</span> - \n <span class=\"adr\">\n <span class=\"locality\">Cambridge</span> \n <span class=\"country-name\">UK</span>\n </span>\n </p>\n</div>";
+ var expected = {"items":[{"type":["h-product"],"properties":{"name":["Raspberry Pi"],"photo":["http://upload.wikimedia.org/wikipedia/commons/thumb/3/3d/RaspberryPi.jpg/320px-RaspberryPi.jpg"],"description":[{"value":"The Raspberry Pi is a credit-card sized computer that plugs into your TV and a keyboard. It’s a capable little PC which can be used for many of the things that your desktop PC does, like spreadsheets, word-processing and games. It also plays high-definition video. We want to see it being used by kids all over the world to learn programming.","html":"The Raspberry Pi is a credit-card sized computer that plugs into your TV and a keyboard. It’s a capable little PC which can be used for many of the things that your desktop PC does, like spreadsheets, word-processing and games. It also plays high-definition video. We want to see it being used by kids all over the world to learn programming."}],"url":["http://www.raspberrypi.org/"],"price":["£29.95"],"review":[{"value":"9.2 out of \n 10 \n based on 178 reviews","type":["h-review-aggregate"],"properties":{"rating":["9.2"],"average":["9.2"],"best":["10"],"count":["178"]}}],"category":["Computer","Education"],"brand":[{"value":"The Raspberry Pi Foundation","type":["h-card"],"properties":{"name":["The Raspberry Pi Foundation"],"org":["The Raspberry Pi Foundation"],"adr":[{"value":"Cambridge \n UK","type":["h-adr"],"properties":{"locality":["Cambridge"],"country-name":["UK"]}}]}}]}}],"rels":{"tag":["http://en.wikipedia.org/wiki/computer","http://en.wikipedia.org/wiki/education"]},"rel-urls":{"http://en.wikipedia.org/wiki/computer":{"text":"Computer","rels":["tag"]},"http://en.wikipedia.org/wiki/education":{"text":"Education","rels":["tag"]}}};
+
+ it('aggregate', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hproduct-simpleproperties.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hproduct-simpleproperties.js
new file mode 100644
index 000000000..7ec61f27b
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hproduct-simpleproperties.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hproduct/simpleproperties
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hproduct', function() {
+ var htmlFragment = "<meta charset=\"utf-8\">\n<div class=\"hproduct\">\n <h2 class=\"fn\">Raspberry Pi</h2>\n <img class=\"photo\" src=\"http://upload.wikimedia.org/wikipedia/commons/thumb/3/3d/RaspberryPi.jpg/320px-RaspberryPi.jpg\" />\n <p class=\"description\">The Raspberry Pi is a credit-card sized computer that plugs into your TV and a keyboard. It’s a capable little PC which can be used for many of the things that your desktop PC does, like spreadsheets, word-processing and games. It also plays high-definition video. We want to see it being used by kids all over the world to learn programming.</p>\n <a class=\"url\" href=\"http://www.raspberrypi.org/\">More info about the Raspberry Pi</a>\n <p class=\"price\">£29.95</p>\n <p class=\"review hreview\"><span class=\"rating\">4.5</span> out of 5</p>\n <p>Categories: \n <a rel=\"tag\" href=\"http://en.wikipedia.org/wiki/computer\" class=\"category\">Computer</a>, \n <a rel=\"tag\" href=\"http://en.wikipedia.org/wiki/education\" class=\"category\">Education</a>\n </p>\n</div>";
+ var expected = {"items":[{"type":["h-product"],"properties":{"name":["Raspberry Pi"],"photo":["http://upload.wikimedia.org/wikipedia/commons/thumb/3/3d/RaspberryPi.jpg/320px-RaspberryPi.jpg"],"description":[{"value":"The Raspberry Pi is a credit-card sized computer that plugs into your TV and a keyboard. It’s a capable little PC which can be used for many of the things that your desktop PC does, like spreadsheets, word-processing and games. It also plays high-definition video. We want to see it being used by kids all over the world to learn programming.","html":"The Raspberry Pi is a credit-card sized computer that plugs into your TV and a keyboard. It’s a capable little PC which can be used for many of the things that your desktop PC does, like spreadsheets, word-processing and games. It also plays high-definition video. We want to see it being used by kids all over the world to learn programming."}],"url":["http://www.raspberrypi.org/"],"price":["£29.95"],"category":["Computer","Education"],"review":[{"value":"4.5 out of 5","type":["h-review"],"properties":{"rating":["4.5"]}}]}}],"rels":{"tag":["http://en.wikipedia.org/wiki/computer","http://en.wikipedia.org/wiki/education"]},"rel-urls":{"http://en.wikipedia.org/wiki/computer":{"text":"Computer","rels":["tag"]},"http://en.wikipedia.org/wiki/education":{"text":"Education","rels":["tag"]}}};
+
+ it('simpleproperties', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hresume-affiliation.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hresume-affiliation.js
new file mode 100644
index 000000000..d580d68db
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hresume-affiliation.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hresume/affiliation
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hresume', function() {
+ var htmlFragment = "<div class=\"hresume\">\n <p>\n <span class=\"contact vcard\"><span class=\"fn\">Tim Berners-Lee</span></span>, \n <span class=\"summary\">invented the World Wide Web</span>.\n </p>\n Belongs to following groups:\n <p> \n <a class=\"affiliation vcard\" href=\"http://www.w3.org/\">\n <img class=\"fn photo\" alt=\"W3C\" src=\"http://www.w3.org/Icons/WWW/w3c_home_nb.png\" />\n </a>\n </p> \n</div>";
+ var expected = {"items":[{"type":["h-resume"],"properties":{"contact":[{"value":"Tim Berners-Lee","type":["h-card"],"properties":{"name":["Tim Berners-Lee"]}}],"summary":["invented the World Wide Web"],"affiliation":[{"type":["h-card"],"properties":{"name":["W3C"],"photo":["http://www.w3.org/Icons/WWW/w3c_home_nb.png"]}}]}}],"rels":{},"rel-urls":{}};
+
+ it('affiliation', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hresume-contact.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hresume-contact.js
new file mode 100644
index 000000000..595087af4
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hresume-contact.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hresume/contact
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hresume', function() {
+ var htmlFragment = "<div class=\"hresume\">\n <div class=\"contact vcard\">\n <p class=\"fn\">Tim Berners-Lee</p>\n <p class=\"org\">MIT</p>\n <p class=\"adr\">\n <span class=\"street-address\">32 Vassar Street</span>, \n <span class=\"extended-address\">Room 32-G524</span>, \n <span class=\"locality\">Cambridge</span>, \n <span class=\"region\">MA</span> \n <span class=\"postal-code\">02139</span>, \n <span class=\"country-name\">USA</span>. \n (<span class=\"type\">Work</span>)\n </p>\n <p>Tel:<span class=\"tel\">+1 (617) 253 5702</span></p>\n <p>Email:<a class=\"email\" href=\"mailto:timbl@w3.org\">timbl@w3.org</a></p>\n </div>\n <p class=\"summary\">Invented the World Wide Web.</p>\n</div>";
+ var expected = {"items":[{"type":["h-resume"],"properties":{"contact":[{"value":"Tim Berners-Lee","type":["h-card"],"properties":{"name":["Tim Berners-Lee"],"org":["MIT"],"adr":[{"value":"32 Vassar Street, \n Room 32-G524, \n Cambridge, \n MA \n 02139, \n USA. \n (Work)","type":["h-adr"],"properties":{"street-address":["32 Vassar Street"],"extended-address":["Room 32-G524"],"locality":["Cambridge"],"region":["MA"],"postal-code":["02139"],"country-name":["USA"]}}],"tel":["+1 (617) 253 5702"],"email":["mailto:timbl@w3.org"]}}],"summary":["Invented the World Wide Web."]}}],"rels":{},"rel-urls":{}};
+
+ it('contact', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hresume-education.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hresume-education.js
new file mode 100644
index 000000000..7a0114f53
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hresume-education.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hresume/education
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hresume', function() {
+ var htmlFragment = "<div class=\"hresume\">\n <div class=\"contact vcard\">\n <p class=\"fn\">Tim Berners-Lee</p>\n <p class=\"title\">Director of the World Wide Web Foundation</p>\n </div>\n <p class=\"summary\">Invented the World Wide Web.</p><hr />\n <p class=\"education vevent vcard\">\n <span class=\"fn summary org\">The Queen's College, Oxford University</span>, \n <span class=\"description\">BA Hons (I) Physics</span> \n <time class=\"dtstart\" datetime=\"1973-09\">1973</time> –\n <time class=\"dtend\" datetime=\"1976-06\">1976</time>\n </p>\n</div>";
+ var expected = {"items":[{"type":["h-resume"],"properties":{"contact":[{"value":"Tim Berners-Lee","type":["h-card"],"properties":{"name":["Tim Berners-Lee"],"job-title":["Director of the World Wide Web Foundation"]}}],"summary":["Invented the World Wide Web."],"education":[{"value":"The Queen's College, Oxford University","type":["h-event","h-card"],"properties":{"name":["The Queen's College, Oxford University"],"org":["The Queen's College, Oxford University"],"description":["BA Hons (I) Physics"],"start":["1973-09"],"end":["1976-06"]}}]}}],"rels":{},"rel-urls":{}};
+
+ it('education', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hresume-skill.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hresume-skill.js
new file mode 100644
index 000000000..b08256700
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hresume-skill.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hresume/skill
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hresume', function() {
+ var htmlFragment = "<div class=\"hresume\"> \n <p>\n <span class=\"contact vcard\"><span class=\"fn\">Tim Berners-Lee</span></span>, \n <span class=\"summary\">invented the World Wide Web</span>.\n </p>\n Skills: \n <ul>\n <li><a class=\"skill\" rel=\"tag\" href=\"http://example.com/skills/informationsystems\">information systems</a></li>\n <li><a class=\"skill\" rel=\"tag\" href=\"http://example.com/skills/advocacy\">advocacy</a></li>\n <li><a class=\"skill\" rel=\"tag\" href=\"http://example.com/skills/leadership\">leadership</a></li>\n </ul>\n</div>";
+ var expected = {"items":[{"type":["h-resume"],"properties":{"contact":[{"value":"Tim Berners-Lee","type":["h-card"],"properties":{"name":["Tim Berners-Lee"]}}],"summary":["invented the World Wide Web"],"skill":["information systems","advocacy","leadership"]}}],"rels":{"tag":["http://example.com/skills/informationsystems","http://example.com/skills/advocacy","http://example.com/skills/leadership"]},"rel-urls":{"http://example.com/skills/informationsystems":{"text":"information systems","rels":["tag"]},"http://example.com/skills/advocacy":{"text":"advocacy","rels":["tag"]},"http://example.com/skills/leadership":{"text":"leadership","rels":["tag"]}}};
+
+ it('skill', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hresume-work.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hresume-work.js
new file mode 100644
index 000000000..4ece3a389
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hresume-work.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hresume/work
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hresume', function() {
+ var htmlFragment = "<meta charset=\"utf-8\">\n<div class=\"hresume\">\n <div class=\"contact vcard\">\n <p class=\"fn\">Tim Berners-Lee</p>\n <p class=\"title\">Director of the World Wide Web Foundation</p>\n </div>\n <p class=\"summary\">Invented the World Wide Web.</p><hr />\n <div class=\"experience vevent vcard\">\n <p class=\"title\">Director</p>\n <p><a class=\"fn summary org url\" href=\"http://www.webfoundation.org/\">World Wide Web Foundation</a></p>\n <p>\n <time class=\"dtstart\" datetime=\"2009-01-18\">Jan 2009</time> – Present\n <time class=\"duration\" datetime=\"P2Y11M\">(2 years 11 month)</time>\n </p>\n </div>\n</div>";
+ var expected = {"items":[{"type":["h-resume"],"properties":{"contact":[{"value":"Tim Berners-Lee","type":["h-card"],"properties":{"name":["Tim Berners-Lee"],"job-title":["Director of the World Wide Web Foundation"]}}],"summary":["Invented the World Wide Web."],"experience":[{"value":"World Wide Web Foundation","type":["h-event","h-card"],"properties":{"job-title":["Director"],"name":["World Wide Web Foundation"],"org":["World Wide Web Foundation"],"url":["http://www.webfoundation.org/"],"start":["2009-01-18"],"duration":["P2Y11M"]}}]}}],"rels":{},"rel-urls":{}};
+
+ it('work', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hreview-aggregate-hcard.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hreview-aggregate-hcard.js
new file mode 100644
index 000000000..6cdf65484
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hreview-aggregate-hcard.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hreview-aggregate/hcard
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hreview-aggregate', function() {
+ var htmlFragment = "<div class=\"hreview-aggregate\">\n <div class=\"item vcard\">\n <h3 class=\"fn org\">Mediterranean Wraps</h3> \n <p>\n <span class=\"adr\">\n <span class=\"street-address\">433 S California Ave</span>, \n <span class=\"locality\">Palo Alto</span>, \n <span class=\"region\">CA</span></span> - \n \n <span class=\"tel\">(650) 321-8189</span>\n </p>\n </div> \n <p class=\"rating\">\n <span class=\"average value\">9.2</span> out of \n <span class=\"best\">10</span> \n based on <span class=\"count\">17</span> reviews\n </p>\n</div>";
+ var expected = {"items":[{"type":["h-review-aggregate"],"properties":{"item":[{"value":"Mediterranean Wraps","type":["h-item","h-card"],"properties":{"name":["Mediterranean Wraps"],"org":["Mediterranean Wraps"],"adr":[{"value":"433 S California Ave, \n Palo Alto, \n CA","type":["h-adr"],"properties":{"street-address":["433 S California Ave"],"locality":["Palo Alto"],"region":["CA"]}}],"tel":["(650) 321-8189"]}}],"rating":["9.2"],"average":["9.2"],"best":["10"],"count":["17"]}}],"rels":{},"rel-urls":{}};
+
+ it('hcard', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hreview-aggregate-justahyperlink.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hreview-aggregate-justahyperlink.js
new file mode 100644
index 000000000..56d106fdb
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hreview-aggregate-justahyperlink.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hreview-aggregate/justahyperlink
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hreview-aggregate', function() {
+ var htmlFragment = "<p class=\"hreview-aggregate\">\n <span class=\"item\">\n <a class=\"fn url\" href=\"http://example.com/mediterraneanwraps\">Mediterranean Wraps</a>\n </span> - Rated: \n <span class=\"rating\">4.5</span> out of 5 (<span class=\"count\">6</span> reviews)\n</p>";
+ var expected = {"items":[{"type":["h-review-aggregate"],"properties":{"item":[{"value":"Mediterranean Wraps","type":["h-item"],"properties":{"name":["Mediterranean Wraps"],"url":["http://example.com/mediterraneanwraps"]}}],"rating":["4.5"],"count":["6"]}}],"rels":{},"rel-urls":{}};
+
+ it('justahyperlink', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hreview-aggregate-vevent.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hreview-aggregate-vevent.js
new file mode 100644
index 000000000..896bbdc1d
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hreview-aggregate-vevent.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hreview-aggregate/vevent
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hreview-aggregate', function() {
+ var htmlFragment = "<div class=\"hreview-aggregate\">\n <div class=\"item vevent\">\n <h3 class=\"summary\">Fullfrontal</h3>\n <p class=\"description\">A one day JavaScript Conference held in Brighton</p>\n <p><time class=\"dtstart\" datetime=\"2012-11-09\">9th November 2012</time></p> \n </div> \n \n <p class=\"rating\">\n <span class=\"average value\">9.9</span> out of \n <span class=\"best\">10</span> \n based on <span class=\"count\">62</span> reviews\n </p>\n</div>";
+ var expected = {"items":[{"type":["h-review-aggregate"],"properties":{"item":[{"value":"Fullfrontal","type":["h-item","h-event"],"properties":{"name":["Fullfrontal"],"description":["A one day JavaScript Conference held in Brighton"],"start":["2012-11-09"]}}],"rating":["9.9"],"average":["9.9"],"best":["10"],"count":["62"]}}],"rels":{},"rel-urls":{}};
+
+ it('vevent', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hreview-item.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hreview-item.js
new file mode 100644
index 000000000..4a00ac46a
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hreview-item.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hreview/item
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hreview', function() {
+ var htmlFragment = "<base href=\"http://example.com\">\n<div class=\"hreview\">\n <p class=\"item\">\n <img class=\"photo\" src=\"images/photo.gif\" />\n <a class=\"fn url\" href=\"http://example.com/crepeoncole\">Crepes on Cole</a>\n </p>\n <p><span class=\"rating\">5</span> out of 5 stars</p>\n</div>";
+ var expected = {"items":[{"type":["h-review"],"properties":{"item":[{"value":"Crepes on Cole","type":["h-item"],"properties":{"photo":["http://example.com/images/photo.gif"],"name":["Crepes on Cole"],"url":["http://example.com/crepeoncole"]}}],"rating":["5"]}}],"rels":{},"rel-urls":{}};
+
+ it('item', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-hreview-vcard.js b/toolkit/components/microformats/test/standards-tests/mf-v1-hreview-vcard.js
new file mode 100644
index 000000000..d59decb7f
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-hreview-vcard.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/hreview/vcard
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('hreview', function() {
+ var htmlFragment = "<div class=\"hreview\">\n <span><span class=\"rating\">5</span> out of 5 stars</span>\n <h4 class=\"summary\">Crepes on Cole is awesome</h4>\n <span class=\"reviewer vcard\">\n Reviewer: <span class=\"fn\">Tantek</span> - \n </span>\n <time class=\"reviewed\" datetime=\"2005-04-18\">April 18, 2005</time>\n <div class=\"description\">\n <p class=\"item vcard\">\n <span class=\"fn org\">Crepes on Cole</span> is one of the best little \n creperies in <span class=\"adr\"><span class=\"locality\">San Francisco</span></span>.\n Excellent food and service. Plenty of tables in a variety of sizes \n for parties large and small. Window seating makes for excellent \n people watching to/from the N-Judah which stops right outside. \n I've had many fun social gatherings here, as well as gotten \n plenty of work done thanks to neighborhood WiFi.\n </p>\n </div>\n <p>Visit date: <span>April 2005</span></p>\n <p>Food eaten: <a rel=\"tag\" href=\"http://en.wikipedia.org/wiki/crepe\">crepe</a></p>\n <p>Permanent link for review: <a rel=\"self bookmark\" href=\"http://example.com/crepe\">http://example.com/crepe</a></p>\n <p><a rel=\"license\" href=\"http://en.wikipedia.org/wiki/Wikipedia:Text_of_Creative_Commons_Attribution-ShareAlike_3.0_Unported_License\">Creative Commons Attribution-ShareAlike License</a></p>\n</div>";
+ var expected = {"items":[{"type":["h-review"],"properties":{"rating":["5"],"name":["Crepes on Cole is awesome"],"reviewer":[{"value":"Tantek","type":["h-card"],"properties":{"name":["Tantek"]}}],"description":[{"value":"Crepes on Cole is one of the best little \n creperies in San Francisco.\n Excellent food and service. Plenty of tables in a variety of sizes \n for parties large and small. Window seating makes for excellent \n people watching to/from the N-Judah which stops right outside. \n I've had many fun social gatherings here, as well as gotten \n plenty of work done thanks to neighborhood WiFi.","html":"\n <p class=\"item vcard\">\n <span class=\"fn org\">Crepes on Cole</span> is one of the best little \n creperies in <span class=\"adr\"><span class=\"locality\">San Francisco</span></span>.\n Excellent food and service. Plenty of tables in a variety of sizes \n for parties large and small. Window seating makes for excellent \n people watching to/from the N-Judah which stops right outside. \n I've had many fun social gatherings here, as well as gotten \n plenty of work done thanks to neighborhood WiFi.\n </p>\n "}],"item":[{"value":"Crepes on Cole","type":["h-item","h-card"],"properties":{"name":["Crepes on Cole"],"org":["Crepes on Cole"],"adr":[{"value":"San Francisco","type":["h-adr"],"properties":{"locality":["San Francisco"]}}]}}],"category":["crepe"],"url":["http://example.com/crepe"]}}],"rels":{"tag":["http://en.wikipedia.org/wiki/crepe"],"self":["http://example.com/crepe"],"bookmark":["http://example.com/crepe"],"license":["http://en.wikipedia.org/wiki/Wikipedia:Text_of_Creative_Commons_Attribution-ShareAlike_3.0_Unported_License"]},"rel-urls":{"http://en.wikipedia.org/wiki/crepe":{"text":"crepe","rels":["tag"]},"http://example.com/crepe":{"text":"http://example.com/crepe","rels":["self","bookmark"]},"http://en.wikipedia.org/wiki/Wikipedia:Text_of_Creative_Commons_Attribution-ShareAlike_3.0_Unported_License":{"text":"Creative Commons Attribution-ShareAlike License","rels":["license"]}}};
+
+ it('vcard', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-includes-hcarditemref.js b/toolkit/components/microformats/test/standards-tests/mf-v1-includes-hcarditemref.js
new file mode 100644
index 000000000..5ffa373d7
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-includes-hcarditemref.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/includes/hcarditemref
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('includes', function() {
+ var htmlFragment = "<div class=\"vcard\" itemref=\"mozilla-org mozilla-adr\">\n <span class=\"name\">Brendan Eich</span>\n</div>\n<div class=\"vcard\" itemref=\"mozilla-org mozilla-adr\">\n <span class=\"name\">Mitchell Baker</span>\n</div>\n\n<p id=\"mozilla-org\" class=\"org\">Mozilla</p>\n<p id=\"mozilla-adr\" class=\"adr\">\n <span class=\"street-address\">665 3rd St.</span> \n <span class=\"extended-address\">Suite 207</span> \n <span class=\"locality\">San Francisco</span>, \n <span class=\"region\">CA</span> \n <span class=\"postal-code\">94107</span> \n <span class=\"country-name\">U.S.A.</span> \n</p>";
+ var expected = {"items":[{"type":["h-card"],"properties":{"org":["Mozilla"],"adr":[{"value":"665 3rd St. \n Suite 207 \n San Francisco, \n CA \n 94107 \n U.S.A.","type":["h-adr"],"properties":{"street-address":["665 3rd St."],"extended-address":["Suite 207"],"locality":["San Francisco"],"region":["CA"],"postal-code":["94107"],"country-name":["U.S.A."]}}]}},{"type":["h-card"],"properties":{"org":["Mozilla"],"adr":[{"value":"665 3rd St. \n Suite 207 \n San Francisco, \n CA \n 94107 \n U.S.A.","type":["h-adr"],"properties":{"street-address":["665 3rd St."],"extended-address":["Suite 207"],"locality":["San Francisco"],"region":["CA"],"postal-code":["94107"],"country-name":["U.S.A."]}}]}},{"type":["h-adr"],"properties":{"street-address":["665 3rd St."],"extended-address":["Suite 207"],"locality":["San Francisco"],"region":["CA"],"postal-code":["94107"],"country-name":["U.S.A."]}}],"rels":{},"rel-urls":{}};
+
+ it('hcarditemref', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-includes-heventitemref.js b/toolkit/components/microformats/test/standards-tests/mf-v1-includes-heventitemref.js
new file mode 100644
index 000000000..b3a16025b
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-includes-heventitemref.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/includes/heventitemref
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('includes', function() {
+ var htmlFragment = "<div class=\"vevent\" itemref=\"io-session07\">\n <span class=\"name\">Monetizing Android Apps</span> - spaekers: \n <span class=\"speaker\">Chrix Finne</span>, \n <span class=\"speaker\">Kenneth Lui</span> - \n <span itemref=\"io-location\" class=\"location adr\">\n <span class=\"extended-address\">Room 10</span>\n </span> \n</div>\n<div class=\"vevent\" itemref=\"io-session07\">\n <span class=\"name\">New Low-Level Media APIs in Android</span> - spaekers: \n <span class=\"speaker\">Dave Burke</span> -\n <span itemref=\"io-location\" class=\"location adr\">\n <span class=\"extended-address\">Room 11</span>\n </span> \n</div>\n\n<p id=\"io-session07\">\n Session 01 is between: \n <time class=\"dtstart\" datetime=\"2012-06-27T15:45:00-0800\">3:45PM</time> to \n <time class=\"dtend\" datetime=\"2012-06-27T16:45:00-0800\">4:45PM</time> \n</p> \n<p id=\"io-location\">\n <span class=\"extended-address\">Moscone Center</span>, \n <span class=\"locality\">San Francisco</span> \n</p>";
+ var expected = {"items":[{"type":["h-event"],"properties":{"location":[{"value":"Room 10\n \n Moscone Center, \n San Francisco","type":["h-adr"],"properties":{"extended-address":["Room 10","Moscone Center"],"locality":["San Francisco"]}}],"start":["2012-06-27 15:45:00-08:00"],"end":["2012-06-27 16:45:00-08:00"]}},{"type":["h-event"],"properties":{"location":[{"value":"Room 11\n \n Moscone Center, \n San Francisco","type":["h-adr"],"properties":{"extended-address":["Room 11","Moscone Center"],"locality":["San Francisco"]}}],"start":["2012-06-27 15:45:00-08:00"],"end":["2012-06-27 16:45:00-08:00"]}}],"rels":{},"rel-urls":{}};
+
+ it('heventitemref', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-includes-hyperlink.js b/toolkit/components/microformats/test/standards-tests/mf-v1-includes-hyperlink.js
new file mode 100644
index 000000000..3a789bb1b
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-includes-hyperlink.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/includes/hyperlink
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('includes', function() {
+ var htmlFragment = "<div class=\"vcard\">\n <span class=\"name\">Ben Ward</span>\n <a class=\"include\" href=\"#twitter\">Twitter</a>\n</div>\n<div class=\"vcard\">\n <span class=\"name\">Dan Webb</span>\n <a class=\"include\" href=\"#twitter\">Twitter</a>\n</div>\n\n<div id=\"twitter\">\n <p class=\"org\">Twitter</p>\n <p class=\"adr\">\n <span class=\"street-address\">1355 Market St</span>,\n <span class=\"locality\">San Francisco</span>, \n <span class=\"region\">CA</span>\n <span class=\"postal-code\">94103</span>\n </p>\n</div>";
+ var expected = {"items":[{"type":["h-card"],"properties":{"org":["Twitter"],"adr":[{"value":"1355 Market St,\n San Francisco, \n CA\n 94103","type":["h-adr"],"properties":{"street-address":["1355 Market St"],"locality":["San Francisco"],"region":["CA"],"postal-code":["94103"]}}]}},{"type":["h-card"],"properties":{"org":["Twitter"],"adr":[{"value":"1355 Market St,\n San Francisco, \n CA\n 94103","type":["h-adr"],"properties":{"street-address":["1355 Market St"],"locality":["San Francisco"],"region":["CA"],"postal-code":["94103"]}}]}},{"type":["h-adr"],"properties":{"street-address":["1355 Market St"],"locality":["San Francisco"],"region":["CA"],"postal-code":["94103"]}}],"rels":{},"rel-urls":{}};
+
+ it('hyperlink', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-includes-object.js b/toolkit/components/microformats/test/standards-tests/mf-v1-includes-object.js
new file mode 100644
index 000000000..3bc15bd45
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-includes-object.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/includes/object
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('includes', function() {
+ var htmlFragment = "<div class=\"vevent\">\n <span class=\"name\">HTML5 & CSS3 latest features in action!</span> - \n <span class=\"speaker\">David Rousset</span> -\n <time class=\"dtstart\" datetime=\"2012-10-30T11:45:00-08:00\">Tue 11:45am</time>\n <object data=\"#buildconf\" class=\"include\" type=\"text/html\" height=\"0\" width=\"0\"></object>\n</div>\n<div class=\"vevent\">\n <span class=\"name\">Building High-Performing JavaScript for Modern Engines</span> -\n <span class=\"speaker\">John-David Dalton</span> and \n <span class=\"speaker\">Amanda Silver</span> -\n <time class=\"dtstart\" datetime=\"2012-10-31T11:15:00-08:00\">Wed 11:15am</time>\n <object data=\"#buildconf\" class=\"include\" type=\"text/html\" height=\"0\" width=\"0\"></object>\n</div>\n\n\n<div id=\"buildconf\">\n <p class=\"summary\">Build Conference</p>\n <p class=\"location adr\">\n <span class=\"locality\">Redmond</span>, \n <span class=\"region\">Washington</span>, \n <span class=\"country-name\">USA</span>\n </p>\n</div>";
+ var expected = {"items":[{"type":["h-event"],"properties":{"start":["2012-10-30 11:45:00-08:00"],"name":["Build Conference"],"location":[{"value":"Redmond, \n Washington, \n USA","type":["h-adr"],"properties":{"locality":["Redmond"],"region":["Washington"],"country-name":["USA"]}}]}},{"type":["h-event"],"properties":{"start":["2012-10-31 11:15:00-08:00"],"name":["Build Conference"],"location":[{"value":"Redmond, \n Washington, \n USA","type":["h-adr"],"properties":{"locality":["Redmond"],"region":["Washington"],"country-name":["USA"]}}]}},{"type":["h-adr"],"properties":{"locality":["Redmond"],"region":["Washington"],"country-name":["USA"]}}],"rels":{},"rel-urls":{}};
+
+ it('object', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v1-includes-table.js b/toolkit/components/microformats/test/standards-tests/mf-v1-includes-table.js
new file mode 100644
index 000000000..a0d3ef55c
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v1-includes-table.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v1/includes/table
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('includes', function() {
+ var htmlFragment = "<meta charset=\"utf-8\">\n<table>\n <tr>\n <th id=\"org\"><a class=\"url org\" href=\"http://dev.opera.com/\">Opera</a></th>\n </tr>\n <tr>\n <td class=\"vcard\" headers=\"org\"><span class=\"fn\">Chris Mills</span></td>\n </tr>\n <tr>\n <td class=\"vcard\" headers=\"org\"><span class=\"fn\">Erik Möller</span></td>\n </tr>\n </table>";
+ var expected = {"items":[{"type":["h-card"],"properties":{"name":["Chris Mills"],"url":["http://dev.opera.com/"],"org":["Opera"]}},{"type":["h-card"],"properties":{"name":["Erik Möller"],"url":["http://dev.opera.com/"],"org":["Opera"]}}],"rels":{},"rel-urls":{}};
+
+ it('table', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-adr-geo.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-adr-geo.js
new file mode 100644
index 000000000..8ed7d747d
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-adr-geo.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-adr/geo
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-adr', function() {
+ var htmlFragment = "<p class=\"h-adr\">\n <span class=\"p-name\">Bricklayer's Arms</span>\n <span class=\"p-label\"> \n <span class=\"p-street-address\">3 Charlotte Road</span>, \n <span class=\"p-locality\">City of London</span>, \n <span class=\"p-postal-code\">EC2A 3PE</span>, \n <span class=\"p-country-name\">UK</span> \n </span> – \n Geo:(<span class=\"p-geo\">51.526421;-0.081067</span>) \n</p>";
+ var expected = {"items":[{"type":["h-adr"],"properties":{"name":["Bricklayer's Arms"],"label":["3 Charlotte Road, \n City of London, \n EC2A 3PE, \n UK"],"street-address":["3 Charlotte Road"],"locality":["City of London"],"postal-code":["EC2A 3PE"],"country-name":["UK"],"geo":["51.526421;-0.081067"]}}],"rels":{},"rel-urls":{}};
+
+ it('geo', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-adr-geourl.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-adr-geourl.js
new file mode 100644
index 000000000..b97e76f60
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-adr-geourl.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-adr/geourl
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-adr', function() {
+ var htmlFragment = "<p class=\"h-adr\">\n <a class=\"p-name u-geo\" href=\"geo:51.526421;-0.081067;crs=wgs84;u=40\">Bricklayer's Arms</a>, \n <span class=\"p-locality\">London</span> \n</p>";
+ var expected = {"items":[{"type":["h-adr"],"properties":{"name":["Bricklayer's Arms"],"geo":["geo:51.526421;-0.081067;crs=wgs84;u=40"],"locality":["London"],"url":["geo:51.526421;-0.081067;crs=wgs84;u=40"]}}],"rels":{},"rel-urls":{}};
+
+ it('geourl', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-adr-justaname.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-adr-justaname.js
new file mode 100644
index 000000000..c943fbafc
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-adr-justaname.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-adr/justaname
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-adr', function() {
+ var htmlFragment = "<p class=\"h-adr\">665 3rd St. Suite 207 San Francisco, CA 94107 U.S.A.</p>";
+ var expected = {"items":[{"type":["h-adr"],"properties":{"name":["665 3rd St. Suite 207 San Francisco, CA 94107 U.S.A."]}}],"rels":{},"rel-urls":{}};
+
+ it('justaname', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-adr-simpleproperties.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-adr-simpleproperties.js
new file mode 100644
index 000000000..084dac440
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-adr-simpleproperties.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-adr/simpleproperties
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-adr', function() {
+ var htmlFragment = "<p class=\"h-adr\">\n <span class=\"p-street-address\">665 3rd St.</span> \n <span class=\"p-extended-address\">Suite 207</span> \n <span class=\"p-locality\">San Francisco</span>, \n <span class=\"p-region\">CA</span> \n <span class=\"p-postal-code\">94107</span> \n <span class=\"p-country-name\">U.S.A.</span> \n</p>";
+ var expected = {"items":[{"type":["h-adr"],"properties":{"street-address":["665 3rd St."],"extended-address":["Suite 207"],"locality":["San Francisco"],"region":["CA"],"postal-code":["94107"],"country-name":["U.S.A."],"name":["665 3rd St. \n Suite 207 \n San Francisco, \n CA \n 94107 \n U.S.A."]}}],"rels":{},"rel-urls":{}};
+
+ it('simpleproperties', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-as-note-note.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-as-note-note.js
new file mode 100644
index 000000000..7e0ac260c
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-as-note-note.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-as-note/note
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-as-note', function() {
+ var htmlFragment = "<!-- http://tantek.com/2015/152/t2/proud-withknown-indieweb-user-empathy -->\n<base href=\"http://tantek.com/\" />\n\n<li class=\"h-entry hentry h-as-note\">\n <div>\n <ul>\n <li>\n <a href=\"152/t1/congrats-fellow-elected-w3cab-members\" id=\"previtem\" title=\"View the previous (older) item in the stream.\"\n rel=\"prev\"><abbr title=\"Previous\">←</abbr></a>\n </li>\n <li>\n <a href=\"152/t3/going-indiewebcamp-2015-portland\" id=\"nextitem\" title=\"View the next (newer) item in the stream\" rel=\"next\"><abbr title=\"Next\">→</abbr></a>\n </li>\n </ul>\n </div>\n <div>In reply to:\n <p>\n <a class=\"u-in-reply-to h-cite\" rel=\"in-reply-to\" href=\"http://werd.io/2015/im-super-proud-of-everything-weve-done-on-withknown-so-far\">http://werd.io/2015/im-super-proud-of-everything-weve-done-on-withknown-so-far</a>\n </p>\n <p>\n <a class=\"u-in-reply-to h-cite\" rel=\"in-reply-to\" href=\"https://twitter.com/benwerd/status/604733231284383744\">https://twitter.com/benwerd/status/604733231284383744</a>\n </p>\n <hr>\n </div>\n <a href=\"../\" class=\"p-author h-card\" rel=\"author\" title=\"Tantek Çelik\"><img src=\"/images/photo.gif\" alt=\"Tantek Çelik\"></a>\n <p class=\"p-name entry-title e-content entry-content article\">\n <a class=\"auto-link h-x-username\" href=\"https://twitter.com/benwerd\">@benwerd</a>\n <a class=\"auto-link h-x-username\" href=\"https://twitter.com/erinjo\">@erinjo</a>also proud of you &amp;\n <a class=\"auto-link h-x-username\" href=\"https://twitter.com/withknown\">@withknown</a>— so much #indieweb &amp; especially user empathy. Keep up the great work!</p>\n <span>\n <span class=\"dt-published published dt-updated updated\">\n <time class=\"value\" datetime=\"22:20-0700\">22:20</time>on\n <time class=\"value\">2015-06-01</time>\n </span>\n <span class=\"lt\">(ttk.me t4bT2)</span>using\n <span class=\"using\">BBEdit</span>\n </span>\n <div>\n <form action=\"http://tantek.com/2015/152/t2/proud-withknown-indieweb-user-empathy\">\n <div>\n <label>\n <span class=\"lt\">URL:</span>\n <input class=\"u-url url u-uid uid bookmark\" type=\"url\" size=\"70\" style=\"max-width:100%\" value=\"http://tantek.com/2015/152/t2/proud-withknown-indieweb-user-empathy\">\n </label>\n </div>\n </form>\n </div>\n <div>\n <a class=\"u-syndication\" rel=\"syndication\" style=\"float:right;\" href=\"https://twitter.com/t/status/605604965566906369\">\n <img src=\"/images/photo.gif\" style=\"vertical-align:-30%\" alt=\"\"> \n View \n Conversation\n on Twitter\n</a>\n </div>\n</li>";
+ var expected = {"items":[{"type":["h-entry","h-as-note"],"properties":{"in-reply-to":[{"value":"http://werd.io/2015/im-super-proud-of-everything-weve-done-on-withknown-so-far","type":["h-cite"],"properties":{"name":["http://werd.io/2015/im-super-proud-of-everything-weve-done-on-withknown-so-far"],"url":["http://werd.io/2015/im-super-proud-of-everything-weve-done-on-withknown-so-far"]}},{"value":"https://twitter.com/benwerd/status/604733231284383744","type":["h-cite"],"properties":{"name":["https://twitter.com/benwerd/status/604733231284383744"],"url":["https://twitter.com/benwerd/status/604733231284383744"]}}],"author":[{"type":["h-card"],"properties":{"name":["Tantek Çelik"],"photo":["http://tantek.com/images/photo.gif"],"url":["http://tantek.com/"]}}],"name":["@benwerd\n @erinjoalso proud of you &\n @withknown— so much #indieweb & especially user empathy. Keep up the great work!"],"content":[{"value":"@benwerd\n @erinjoalso proud of you &\n @withknown— so much #indieweb & especially user empathy. Keep up the great work!","html":"\n <a class=\"auto-link h-x-username\" href=\"https://twitter.com/benwerd\">@benwerd</a>\n <a class=\"auto-link h-x-username\" href=\"https://twitter.com/erinjo\">@erinjo</a>also proud of you &\n <a class=\"auto-link h-x-username\" href=\"https://twitter.com/withknown\">@withknown</a>— so much #indieweb & especially user empathy. Keep up the great work!"}],"published":["2015-06-01 22:20-07:00"],"updated":["2015-06-01 22:20-07:00"],"url":["http://tantek.com/2015/152/t2/proud-withknown-indieweb-user-empathy"],"uid":["http://tantek.com/2015/152/t2/proud-withknown-indieweb-user-empathy"],"syndication":["https://twitter.com/t/status/605604965566906369"]},"children":[{"value":"@benwerd","type":["h-x-username"],"properties":{"name":["@benwerd"],"url":["https://twitter.com/benwerd"]}},{"value":"@erinjo","type":["h-x-username"],"properties":{"name":["@erinjo"],"url":["https://twitter.com/erinjo"]}},{"value":"@withknown","type":["h-x-username"],"properties":{"name":["@withknown"],"url":["https://twitter.com/withknown"]}}]}],"rels":{"prev":["http://tantek.com/152/t1/congrats-fellow-elected-w3cab-members"],"next":["http://tantek.com/152/t3/going-indiewebcamp-2015-portland"],"in-reply-to":["http://werd.io/2015/im-super-proud-of-everything-weve-done-on-withknown-so-far","https://twitter.com/benwerd/status/604733231284383744"],"author":["http://tantek.com/"],"syndication":["https://twitter.com/t/status/605604965566906369"]},"rel-urls":{"http://tantek.com/152/t1/congrats-fellow-elected-w3cab-members":{"title":"View the previous (older) item in the stream.","text":"←","rels":["prev"]},"http://tantek.com/152/t3/going-indiewebcamp-2015-portland":{"title":"View the next (newer) item in the stream","text":"→","rels":["next"]},"http://werd.io/2015/im-super-proud-of-everything-weve-done-on-withknown-so-far":{"text":"http://werd.io/2015/im-super-proud-of-everything-weve-done-on-withknown-so-far","rels":["in-reply-to"]},"https://twitter.com/benwerd/status/604733231284383744":{"text":"https://twitter.com/benwerd/status/604733231284383744","rels":["in-reply-to"]},"http://tantek.com/":{"title":"Tantek Çelik","rels":["author"]},"https://twitter.com/t/status/605604965566906369":{"text":"View \n Conversation\n on Twitter","rels":["syndication"]}}};
+
+ it('note', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-baseurl.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-baseurl.js
new file mode 100644
index 000000000..d098db392
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-baseurl.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-card/baseurl
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-card', function() {
+ var htmlFragment = "<base href=\"http://example.org\"/>\n<div class=\"h-card\">\n <a class=\"p-name u-url\" href=\"http://blog.lizardwrangler.com/\">Mitchell Baker</a> \n (<a class=\"p-org h-card\" href=\"bios/mitchell-baker/\">Mozilla Foundation</a>)\n <img class=\"u-photo\" src=\"images/photo.gif\"/>\n</div>";
+ var expected = {"items":[{"type":["h-card"],"properties":{"name":["Mitchell Baker"],"url":["http://blog.lizardwrangler.com/"],"org":[{"value":"Mozilla Foundation","type":["h-card"],"properties":{"name":["Mozilla Foundation"],"url":["http://example.org/bios/mitchell-baker/"]}}],"photo":["http://example.org/images/photo.gif"]}}],"rels":{},"rel-urls":{}};
+
+ it('baseurl', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-childimplied.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-childimplied.js
new file mode 100644
index 000000000..3ab1fa8ca
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-childimplied.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-card/childimplied
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-card', function() {
+ var htmlFragment = "<meta charset=\"utf-8\">\n<a class=\"h-card\" href=\"http://people.opera.com/howcome/\" title=\"Håkon Wium Lie, CTO Opera\">\n <article>\n <h2 class=\"p-name\">Håkon Wium Lie</h2>\n <img src=\"http://upload.wikimedia.org/wikipedia/commons/thumb/9/96/H%C3%A5kon-Wium-Lie-2009-03.jpg/215px-H%C3%A5kon-Wium-Lie-2009-03.jpg\" />\n </article>\n</a>";
+ var expected = {"items":[{"type":["h-card"],"properties":{"name":["Håkon Wium Lie"],"photo":["http://upload.wikimedia.org/wikipedia/commons/thumb/9/96/H%C3%A5kon-Wium-Lie-2009-03.jpg/215px-H%C3%A5kon-Wium-Lie-2009-03.jpg"],"url":["http://people.opera.com/howcome/"]}}],"rels":{},"rel-urls":{}};
+
+ it('childimplied', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-extendeddescription.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-extendeddescription.js
new file mode 100644
index 000000000..8ee35b022
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-extendeddescription.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-card/extendeddescription
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-card', function() {
+ var htmlFragment = "<div class=\"h-card\">\n <img class=\"u-photo\" alt=\"photo of Mitchell\" src=\"http://blog.mozilla.org/press/files/2012/04/mitchell-baker.jpg\" />\n <p>\n <a class=\"p-name u-url\" href=\"http://blog.lizardwrangler.com/\">Mitchell Baker</a>\n (<a class=\"u-url\" href=\"https://twitter.com/MitchellBaker\">@MitchellBaker</a>)\n <span class=\"p-org\">Mozilla Foundation</span>\n </p>\n <p class=\"p-note\">Mitchell is responsible for setting the direction and scope of the Mozilla Foundation and its activities.</p>\n <p><span class=\"p-category\">Strategy</span> and <span class=\"p-category\">Leadership</span></p>\n</div>";
+ var expected = {"items":[{"type":["h-card"],"properties":{"photo":["http://blog.mozilla.org/press/files/2012/04/mitchell-baker.jpg"],"url":["http://blog.lizardwrangler.com/","https://twitter.com/MitchellBaker"],"name":["Mitchell Baker"],"org":["Mozilla Foundation"],"note":["Mitchell is responsible for setting the direction and scope of the Mozilla Foundation and its activities."],"category":["Strategy","Leadership"]}}],"rels":{},"rel-urls":{}};
+
+ it('extendeddescription', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-hcard.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-hcard.js
new file mode 100644
index 000000000..961381610
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-hcard.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-card/hcard
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-card', function() {
+ var htmlFragment = "<div class=\"h-card\">\n <a class=\"p-name u-url\" href=\"http://blog.lizardwrangler.com/\">Mitchell Baker</a> \n (<a class=\"p-org h-card\" href=\"http://mozilla.org/\">Mozilla Foundation</a>)\n</div>";
+ var expected = {"items":[{"type":["h-card"],"properties":{"url":["http://blog.lizardwrangler.com/"],"name":["Mitchell Baker"],"org":[{"value":"Mozilla Foundation","type":["h-card"],"properties":{"name":["Mozilla Foundation"],"url":["http://mozilla.org/"]}}]}}],"rels":{},"rel-urls":{}};
+
+ it('hcard', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-horghcard.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-horghcard.js
new file mode 100644
index 000000000..bc6329ae6
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-horghcard.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-card/horghcard
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-card', function() {
+ var htmlFragment = "<div class=\"h-card\">\n <a class=\"p-name u-url\" href=\"http://blog.lizardwrangler.com/\">Mitchell Baker</a> \n (<a class=\"p-org h-card h-org\" href=\"http://mozilla.org/\">Mozilla Foundation</a>)\n</div>";
+ var expected = {"items":[{"type":["h-card"],"properties":{"name":["Mitchell Baker"],"url":["http://blog.lizardwrangler.com/"],"org":[{"value":"Mozilla Foundation","type":["h-card","h-org"],"properties":{"name":["Mozilla Foundation"],"url":["http://mozilla.org/"]}}]}}],"rels":{},"rel-urls":{}};
+
+ it('horghcard', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-hyperlinkedphoto.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-hyperlinkedphoto.js
new file mode 100644
index 000000000..70febcb84
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-hyperlinkedphoto.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-card/hyperlinkedphoto
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-card', function() {
+ var htmlFragment = "<a class=\"h-card\" href=\"http://rohit.khare.org/\">\n <img alt=\"Rohit Khare\" src=\"images/photo.gif\" />\n </a>";
+ var expected = {"items":[{"type":["h-card"],"properties":{"name":["Rohit Khare"],"photo":["http://example.com/images/photo.gif"],"url":["http://rohit.khare.org/"]}}],"rels":{},"rel-urls":{}};
+
+ it('hyperlinkedphoto', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-impliedname.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-impliedname.js
new file mode 100644
index 000000000..bcf45aecb
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-impliedname.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-card/impliedname
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-card', function() {
+ var htmlFragment = "\n<img class=\"h-card\" src=\"jane.html\" alt=\"Jane Doe\"/>\n<area class=\"h-card\" href=\"jane.html\" alt=\"Jane Doe\"></area>\n<abbr class=\"h-card\" title=\"Jane Doe\">JD</abbr>\n\n<div class=\"h-card\"><img src=\"jane.html\" alt=\"Jane Doe\"/></div>\n<div class=\"h-card\"><area href=\"jane.html\" alt=\"Jane Doe\"></area></div>\n<div class=\"h-card\"><abbr title=\"Jane Doe\">JD</abbr></div>\n\n<div class=\"h-card\"><span><img src=\"jane.html\" alt=\"Jane Doe\"/></span></div>\n<div class=\"h-card\"><span><area href=\"jane.html\" alt=\"Jane Doe\"></area></span></div>\n<div class=\"h-card\"><span><abbr title=\"Jane Doe\">JD</abbr></span></div>\n\n<div class=\"h-card\"><img class=\"h-card\" src=\"john.html\" alt=\"John Doe\"/>Name</div>\n<div class=\"h-card\"><span class=\"h-card\"><img src=\"john.html\" alt=\"John Doe\"/>Name</span></div>\n";
+ var expected = {"items":[{"type":["h-card"],"properties":{"name":["Jane Doe"],"photo":["http://example.com/jane.html"]}},{"type":["h-card"],"properties":{"name":["Jane Doe"],"url":["http://example.com/jane.html"]}},{"type":["h-card"],"properties":{"name":["Jane Doe"]}},{"type":["h-card"],"properties":{"name":["Jane Doe"],"photo":["http://example.com/jane.html"]}},{"type":["h-card"],"properties":{"name":["Jane Doe"],"url":["http://example.com/jane.html"]}},{"type":["h-card"],"properties":{"name":["Jane Doe"]}},{"type":["h-card"],"properties":{"name":["Jane Doe"],"photo":["http://example.com/jane.html"]}},{"type":["h-card"],"properties":{"name":["Jane Doe"],"url":["http://example.com/jane.html"]}},{"type":["h-card"],"properties":{"name":["Jane Doe"]}},{"type":["h-card"],"properties":{"name":["Name"]},"children":[{"type":["h-card"],"properties":{"name":["John Doe"],"photo":["http://example.com/john.html"]}}]},{"type":["h-card"],"properties":{"name":["Name"]},"children":[{"value":"Name","type":["h-card"],"properties":{"name":["John Doe"],"photo":["http://example.com/john.html"]}}]}],"rels":{},"rel-urls":{}};
+
+ it('impliedname', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-impliedphoto.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-impliedphoto.js
new file mode 100644
index 000000000..3248a1d0f
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-impliedphoto.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-card/impliedphoto
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-card', function() {
+ var htmlFragment = "<img class=\"h-card\" alt=\"Jane Doe\" src=\"jane.jpeg\"/>\n<object class=\"h-card\" data=\"jane.jpeg\"/>Jane Doe</object>\n\n<div class=\"h-card\"><img alt=\"Jane Doe\" src=\"jane.jpeg\"/></div> \n<div class=\"h-card\"><object data=\"jane.jpeg\"/>Jane Doe</object></div> \n\n<div class=\"h-card\"><span><img alt=\"Jane Doe\" src=\"jane.jpeg\"/></span></div> \n<div class=\"h-card\"><span><object data=\"jane.jpeg\"/>Jane Doe</object></span></div> \n\n<div class=\"h-card\"><img class=\"h-card\" alt=\"Jane Doe\" src=\"jane.jpeg\"/>Jane Doe</div> \n<div class=\"h-card\"><span class=\"h-card\"><object data=\"jane.jpeg\"/>Jane Doe</object></span></div> ";
+ var expected = {"items":[{"type":["h-card"],"properties":{"name":["Jane Doe"],"photo":["http://example.com/jane.jpeg"]}},{"type":["h-card"],"properties":{"name":["Jane Doe"],"photo":["http://example.com/jane.jpeg"]}},{"type":["h-card"],"properties":{"name":["Jane Doe"],"photo":["http://example.com/jane.jpeg"]}},{"type":["h-card"],"properties":{"name":["Jane Doe"],"photo":["http://example.com/jane.jpeg"]}},{"type":["h-card"],"properties":{"name":["Jane Doe"],"photo":["http://example.com/jane.jpeg"]}},{"type":["h-card"],"properties":{"name":["Jane Doe"],"photo":["http://example.com/jane.jpeg"]}},{"type":["h-card"],"properties":{"name":["Jane Doe"]},"children":[{"type":["h-card"],"properties":{"name":["Jane Doe"],"photo":["http://example.com/jane.jpeg"]}}]},{"type":["h-card"],"properties":{"name":["Jane Doe"]},"children":[{"value":"Jane Doe","type":["h-card"],"properties":{"name":["Jane Doe"],"photo":["http://example.com/jane.jpeg"]}}]}],"rels":{},"rel-urls":{}};
+
+ it('impliedphoto', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-impliedurl.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-impliedurl.js
new file mode 100644
index 000000000..4034194ce
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-impliedurl.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-card/impliedurl
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-card', function() {
+ var htmlFragment = "<a class=\"h-card\" href=\"jane.html\">Jane Doe</a>\n<area class=\"h-card\" href=\"jane.html\" alt=\"Jane Doe\"/ >\n<div class=\"h-card\" ><a href=\"jane.html\">Jane Doe</a><p></p></div> \n<div class=\"h-card\" ><area href=\"jane.html\">Jane Doe</area><p></p></div>\n<div class=\"h-card\" ><a class=\"h-card\" href=\"jane.html\">Jane Doe</a><p></p></div> ";
+ var expected = {"items":[{"type":["h-card"],"properties":{"name":["Jane Doe"],"url":["http://example.com/jane.html"]}},{"type":["h-card"],"properties":{"name":["Jane Doe"],"url":["http://example.com/jane.html"]}},{"type":["h-card"],"properties":{"name":["Jane Doe"],"url":["http://example.com/jane.html"]}},{"type":["h-card"],"properties":{"name":["Jane Doe"],"url":["http://example.com/jane.html"]}},{"type":["h-card"],"properties":{"name":["Jane Doe"]},"children":[{"value":"Jane Doe","type":["h-card"],"properties":{"name":["Jane Doe"],"url":["http://example.com/jane.html"]}}]}],"rels":{},"rel-urls":{}};
+
+ it('impliedurl', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-justahyperlink.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-justahyperlink.js
new file mode 100644
index 000000000..5911cc00f
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-justahyperlink.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-card/justahyperlink
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-card', function() {
+ var htmlFragment = "<a class=\"h-card\" href=\"http://benward.me/\">Ben Ward</a>";
+ var expected = {"items":[{"type":["h-card"],"properties":{"name":["Ben Ward"],"url":["http://benward.me/"]}}],"rels":{},"rel-urls":{}};
+
+ it('justahyperlink', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-justaname.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-justaname.js
new file mode 100644
index 000000000..4f239fab5
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-justaname.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-card/justaname
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-card', function() {
+ var htmlFragment = "<p class=\"h-card\">Frances Berriman</p>";
+ var expected = {"items":[{"type":["h-card"],"properties":{"name":["Frances Berriman"]}}],"rels":{},"rel-urls":{}};
+
+ it('justaname', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-nested.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-nested.js
new file mode 100644
index 000000000..da2336e29
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-nested.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-card/nested
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-card', function() {
+ var htmlFragment = "<div class=\"h-card\">\n <a class=\"p-name u-url\" href=\"http://blog.lizardwrangler.com/\">Mitchell Baker</a> \n (<a class=\"h-org h-card\" href=\"http://mozilla.org/\">Mozilla Foundation</a>)\n</div>";
+ var expected = {"items":[{"type":["h-card"],"properties":{"name":["Mitchell Baker"],"url":["http://blog.lizardwrangler.com/"]},"children":[{"value":"Mozilla Foundation","type":["h-org","h-card"],"properties":{"name":["Mozilla Foundation"],"url":["http://mozilla.org/"]}}]}],"rels":{},"rel-urls":{}};
+
+ it('nested', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-p-property.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-p-property.js
new file mode 100644
index 000000000..0a365e34b
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-p-property.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-card/p-property
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-card', function() {
+ var htmlFragment = "<div class=\"h-card\">\n \n <span class=\"p-name\">\n <span class=\"p-given-name value\">John</span> \n <abbr class=\"p-additional-name\" title=\"Peter\">P</abbr> \n <span class=\"p-family-name value \">Doe</span> \n </span>\n <data class=\"p-honorific-suffix\" value=\"MSc\"></data>\n \n \n <br class=\"p-honorific-suffix\" />BSc<br />\n <hr class=\"p-honorific-suffix\" />BA\n \n \n <img class=\"p-honorific-suffix\" src=\"images/logo.gif\" alt=\"PHD\" />\n <img src=\"images/logo.gif\" alt=\"company logos\" usemap=\"#logomap\" />\n <map name=\"logomap\">\n <area class=\"p-org\" shape=\"rect\" coords=\"0,0,82,126\" href=\"madgex.htm\" alt=\"Madgex\" />\n <area class=\"p-org\" shape=\"circle\" coords=\"90,58,3\" href=\"mozilla.htm\" alt=\"Mozilla\" />\n </map>\n</div>";
+ var expected = {"items":[{"type":["h-card"],"properties":{"name":["John Doe"],"given-name":["John"],"additional-name":["Peter"],"family-name":["Doe"],"honorific-suffix":["MSc","PHD"],"org":["Madgex","Mozilla"]}}],"rels":{},"rel-urls":{}};
+
+ it('p-property', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-relativeurls.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-relativeurls.js
new file mode 100644
index 000000000..712a8cf72
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-card-relativeurls.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-card/relativeurls
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-card', function() {
+ var htmlFragment = "<base href=\"http://example.com\" >\n<div class=\"h-card\">\n <a class=\"p-name u-url\" href=\"http://blog.lizardwrangler.com/\">Mitchell Baker</a> \n (<a class=\"p-org h-card\" href=\"bios/mitchell-baker/\">Mozilla Foundation</a>)\n <img class=\"u-photo\" src=\"bios/mitchell-baker/picture.jpeg\"/>\n</div>";
+ var expected = {"items":[{"type":["h-card"],"properties":{"name":["Mitchell Baker"],"url":["http://blog.lizardwrangler.com/"],"org":[{"value":"Mozilla Foundation","type":["h-card"],"properties":{"name":["Mozilla Foundation"],"url":["http://example.com/bios/mitchell-baker/"]}}],"photo":["http://example.com/bios/mitchell-baker/picture.jpeg"]}}],"rels":{},"rel-urls":{}};
+
+ it('relativeurls', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-entry-impliedvalue-nested.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-entry-impliedvalue-nested.js
new file mode 100644
index 000000000..e729b48b0
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-entry-impliedvalue-nested.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-entry/impliedvalue-nested
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-entry', function() {
+ var htmlFragment = "<div class=\"h-entry\">\n <div class=\"u-in-reply-to h-cite\">\n <span class=\"p-author h-card\">\n <span class=\"p-name\">Example Author</span>\n <a class=\"u-url\" href=\"http://example.com\">Home</a>\n </span>\n <a class=\"p-name u-url\" href=\"http://example.com/post\">Example Post</a>\n </div>\n</div>";
+ var expected = {"items":[{"type":["h-entry"],"properties":{"in-reply-to":[{"type":["h-cite"],"properties":{"name":["Example Post"],"url":["http://example.com/post"],"author":[{"type":["h-card"],"properties":{"url":["http://example.com"],"name":["Example Author"]},"value":"Example Author"}]},"value":"http://example.com/post"}],"name":["Example Author\n Home\n \n Example Post"]}}],"rels":{},"rel-urls":{}};
+
+ it('impliedvalue-nested', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-entry-justahyperlink.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-entry-justahyperlink.js
new file mode 100644
index 000000000..1e793e727
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-entry-justahyperlink.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-entry/justahyperlink
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-entry', function() {
+ var htmlFragment = "<a class=\"h-entry\" href=\"http://microformats.org/2012/06/25/microformats-org-at-7\">microformats.org at 7</a>";
+ var expected = {"items":[{"type":["h-entry"],"properties":{"name":["microformats.org at 7"],"url":["http://microformats.org/2012/06/25/microformats-org-at-7"]}}],"rels":{},"rel-urls":{}};
+
+ it('justahyperlink', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-entry-justaname.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-entry-justaname.js
new file mode 100644
index 000000000..f4d31bf87
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-entry-justaname.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-entry/justaname
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-entry', function() {
+ var htmlFragment = "<p class=\"h-entry\">microformats.org at 7</p>";
+ var expected = {"items":[{"type":["h-entry"],"properties":{"name":["microformats.org at 7"]}}],"rels":{},"rel-urls":{}};
+
+ it('justaname', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-entry-summarycontent.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-entry-summarycontent.js
new file mode 100644
index 000000000..b697f6c7c
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-entry-summarycontent.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-entry/summarycontent
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-entry', function() {
+ var htmlFragment = "<meta charset=\"utf-8\">\n<div class=\"h-entry\">\n <h1><a class=\"p-name u-url\" href=\"http://microformats.org/2012/06/25/microformats-org-at-7\">microformats.org at 7</a></h1>\n <div class=\"e-content\">\n <p class=\"p-summary\">Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities.</p>\n\n <p>The microformats tagline “humans first, machines second” \n forms the basis of many of our \n <a href=\"http://microformats.org/wiki/principles\">principles</a>, and \n in that regard, we’d like to recognize a few people and \n thank them for their years of volunteer service </p>\n </div> \n <p>Updated \n <time class=\"dt-updated\" datetime=\"2012-06-25T17:08:26\">June 25th, 2012</time> by\n <a class=\"p-author h-card\" href=\"http://tantek.com/\">Tantek</a>\n </p>\n</div>";
+ var expected = {"items":[{"type":["h-entry"],"properties":{"url":["http://microformats.org/2012/06/25/microformats-org-at-7"],"name":["microformats.org at 7"],"content":[{"value":"Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities.\n\n The microformats tagline “humans first, machines second” \n forms the basis of many of our \n principles, and \n in that regard, we’d like to recognize a few people and \n thank them for their years of volunteer service","html":"\n <p class=\"p-summary\">Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities.</p>\n\n <p>The microformats tagline “humans first, machines second” \n forms the basis of many of our \n <a href=\"http://microformats.org/wiki/principles\">principles</a>, and \n in that regard, we’d like to recognize a few people and \n thank them for their years of volunteer service </p>\n "}],"summary":["Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities."],"updated":["2012-06-25 17:08:26"],"author":[{"value":"Tantek","type":["h-card"],"properties":{"name":["Tantek"],"url":["http://tantek.com/"]}}]}}],"rels":{},"rel-urls":{}};
+
+ it('summarycontent', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-entry-u-property.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-entry-u-property.js
new file mode 100644
index 000000000..510f0aa90
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-entry-u-property.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-entry/u-property
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-entry', function() {
+ var htmlFragment = "<base href=\"http://example.com\">\n<div class=\"h-entry\">\n <p class=\"p-name\">microformats.org at 7</p>\n\n \n <p class=\"u-url\">\n <span class=\"value-title\" title=\"http://microformats.org/\"> </span>\n Article permalink\n </p>\n <p class=\"u-url\">\n <span class=\"value\">http://microformats.org/</span> - \n <span class=\"value\">2012/06/25/microformats-org-at-7</span> \n </p> \n\n <p><a class=\"u-url\" href=\"http://microformats.org/2012/06/25/microformats-org-at-7\">Article permalink</a></p>\n\n <img src=\"images/logo.gif\" alt=\"company logos\" usemap=\"#logomap\" />\n <map name=\"logomap\">\n <area class=\"u-url\" shape=\"rect\" coords=\"0,0,82,126\" href=\"http://microformats.org/\" alt=\"microformats.org\" />\n </map>\n\n <img class=\"u-photo\" src=\"images/logo.gif\" alt=\"company logos\" />\n\n <object class=\"u-url\" data=\"http://microformats.org/wiki/microformats2-parsing\"></object>\n\n <abbr class=\"u-url\" title=\"http://microformats.org/wiki/value-class-pattern\">value-class-pattern</abbr> \n <data class=\"u-url\" value=\"http://microformats.org/wiki/\"></data>\n <p class=\"u-url\">http://microformats.org/discuss</p>\n</div>";
+ var expected = {"items":[{"type":["h-entry"],"properties":{"name":["microformats.org at 7"],"url":["http://microformats.org/","http://microformats.org/2012/06/25/microformats-org-at-7","http://microformats.org/2012/06/25/microformats-org-at-7","http://microformats.org/","http://microformats.org/wiki/microformats2-parsing","http://microformats.org/wiki/value-class-pattern","http://microformats.org/wiki/","http://microformats.org/discuss"],"photo":["http://example.com/images/logo.gif"]}}],"rels":{},"rel-urls":{}};
+
+ it('u-property', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-entry-urlincontent.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-entry-urlincontent.js
new file mode 100644
index 000000000..295ac9925
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-entry-urlincontent.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-entry/urlincontent
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-entry', function() {
+ var htmlFragment = "<div class=\"h-entry\">\n <h1><a class=\"p-name\">Expanding URLs within HTML content</a></h1>\n <div class=\"e-content\">\n <ul>\n <li><a href=\"http://www.w3.org/\">Should not change: http://www.w3.org/</a></li>\n <li><a href=\"http://example.com/\">Should not change: http://example.com/</a></li>\n <li><a href=\"test.html\">File relative: test.html = http://example.com/test.html</a></li>\n <li><a href=\"/test/test.html\">Directory relative: /test/test.html = http://example.com/test/test.html</a></li>\n <li><a href=\"/test.html\">Relative to root: /test.html = http://example.com/test.html</a></li>\n </ul>\n <img src=\"images/photo.gif\" />\n </div> \n</div>";
+ var expected = {"items":[{"type":["h-entry"],"properties":{"name":["Expanding URLs within HTML content"],"content":[{"value":"Should not change: http://www.w3.org/\n Should not change: http://example.com/\n File relative: test.html = http://example.com/test.html\n Directory relative: /test/test.html = http://example.com/test/test.html\n Relative to root: /test.html = http://example.com/test.html","html":"\n <ul>\n <li><a href=\"http://www.w3.org/\">Should not change: http://www.w3.org/</a></li>\n <li><a href=\"http://example.com/\">Should not change: http://example.com/</a></li>\n <li><a href=\"http://example.com/test.html\">File relative: test.html = http://example.com/test.html</a></li>\n <li><a href=\"http://example.com/test/test.html\">Directory relative: /test/test.html = http://example.com/test/test.html</a></li>\n <li><a href=\"http://example.com/test.html\">Relative to root: /test.html = http://example.com/test.html</a></li>\n </ul>\n <img src=\"http://example.com/images/photo.gif\" />\n "}]}}],"rels":{},"rel-urls":{}};
+
+ it('urlincontent', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-ampm.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-ampm.js
new file mode 100644
index 000000000..814c3c42e
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-ampm.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-event/ampm
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-event', function() {
+ var htmlFragment = "<span class=\"h-event\">\n <span class=\"p-name\">The 4th Microformat party</span> will be on \n <ul>\n <li class=\"dt-start\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <span class=\"value\">07:00:00pm \n </span></li>\n <li class=\"dt-start\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <span class=\"value\">07:00:00am \n </span></li>\n <li class=\"dt-start\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <span class=\"value\">07:00pm \n </span></li>\n <li class=\"dt-start\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <span class=\"value\">07pm \n </span></li>\n <li class=\"dt-start\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <span class=\"value\">7pm \n </span></li>\n <li class=\"dt-start\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <span class=\"value\">7:00pm \n </span></li>\n <li class=\"dt-start\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <span class=\"value\">07:00p.m. \n </span></li>\n <li class=\"dt-start\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <span class=\"value\">07:00PM \n </span></li>\n <li class=\"dt-start\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <span class=\"value\">7:00am \n </span></li>\n </ul>\n</span>";
+ var expected = {"items":[{"type":["h-event"],"properties":{"name":["The 4th Microformat party"],"start":["2009-06-26 19:00:00","2009-06-26 07:00:00","2009-06-26 19:00","2009-06-26 19","2009-06-26 19","2009-06-26 19:00","2009-06-26 19:00","2009-06-26 19:00","2009-06-26 07:00"]}}],"rels":{},"rel-urls":{}};
+
+ it('ampm', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-attendees.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-attendees.js
new file mode 100644
index 000000000..2315dbe91
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-attendees.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-event/attendees
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-event', function() {
+ var htmlFragment = "<meta charset=\"utf-8\">\n<div class=\"h-event\">\n <span class=\"p-name\">CPJ Online Press Freedom Summit</span>\n (<time class=\"dt-start\" datetime=\"2012-10-10\">10 Nov 2012</time>) in\n <span class=\"p-location\">San Francisco</span>.\n Attendees:\n <ul>\n <li class=\"p-attendee h-card\">Brian Warner</li>\n <li class=\"p-attendee h-card\">Kyle Machulis</li>\n <li class=\"p-attendee h-card\">Tantek Çelik</li>\n <li class=\"p-attendee h-card\">Sid Sutter</li>\n </ul>\n</div>\n";
+ var expected = {"items":[{"type":["h-event"],"properties":{"name":["CPJ Online Press Freedom Summit"],"start":["2012-10-10"],"location":["San Francisco"],"attendee":[{"value":"Brian Warner","type":["h-card"],"properties":{"name":["Brian Warner"]}},{"value":"Kyle Machulis","type":["h-card"],"properties":{"name":["Kyle Machulis"]}},{"value":"Tantek Çelik","type":["h-card"],"properties":{"name":["Tantek Çelik"]}},{"value":"Sid Sutter","type":["h-card"],"properties":{"name":["Sid Sutter"]}}]}}],"rels":{},"rel-urls":{}};
+
+ it('attendees', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-combining.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-combining.js
new file mode 100644
index 000000000..e91b381ba
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-combining.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-event/combining
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-event', function() {
+ var htmlFragment = "<div class=\"h-event\">\n <a class=\"p-name u-url\" href=\"http://indiewebcamp.com/2012\">\n IndieWebCamp 2012\n </a>\n from <time class=\"dt-start\">2012-06-30</time> \n to <time class=\"dt-end\">2012-07-01</time> at \n <span class=\"p-location h-card\">\n <a class=\"p-name p-org u-url\" href=\"http://geoloqi.com/\">Geoloqi</a>, \n <span class=\"p-street-address\">920 SW 3rd Ave. Suite 400</span>, \n <span class=\"p-locality\">Portland</span>, \n <abbr class=\"p-region\" title=\"Oregon\">OR</abbr>\n </span>\n</div>";
+ var expected = {"items":[{"type":["h-event"],"properties":{"name":["IndieWebCamp 2012"],"url":["http://indiewebcamp.com/2012"],"start":["2012-06-30"],"end":["2012-07-01"],"location":[{"value":"Geoloqi","type":["h-card"],"properties":{"name":["Geoloqi"],"org":["Geoloqi"],"url":["http://geoloqi.com/"],"street-address":["920 SW 3rd Ave. Suite 400"],"locality":["Portland"],"region":["Oregon"]}}]}}],"rels":{},"rel-urls":{}};
+
+ it('combining', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-concatenate.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-concatenate.js
new file mode 100644
index 000000000..897210674
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-concatenate.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-event/concatenate
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-event', function() {
+ var htmlFragment = "<span class=\"h-event\">\n <span class=\"p-name\">The 4th Microformat party</span> will be on \n <span class=\"dt-start\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <time class=\"value\">19:00</time></span> to \n <span class=\"dt-end\"><time class=\"value\">22:00</time></span>.\n</span>";
+ var expected = {"items":[{"type":["h-event"],"properties":{"name":["The 4th Microformat party"],"start":["2009-06-26 19:00"],"end":["2009-06-26 22:00"]}}],"rels":{},"rel-urls":{}};
+
+ it('concatenate', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-dates.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-dates.js
new file mode 100644
index 000000000..c26b5bccc
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-dates.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-event/dates
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-event', function() {
+ var htmlFragment = "<section class=\"h-event\">\n\t<p><span class=\"p-name\">The 4th Microformat party</span> will be on:</p>\n\t<ul>\n\t\t<li><time class=\"dt-start\" datetime=\"2009-06-26T19:00-08:00\">26 July</time></li>\n\t\t<li><time class=\"dt-start\" datetime=\"2009-06-26T19:00-08\">26 July</time></li>\n\t\t<li><time class=\"dt-start\" datetime=\"2009-06-26T19:00-0800\">26 July</time></li>\n\t\t<li><time class=\"dt-start\" datetime=\"2009-06-26T19:00+0800\">26 July</time></li>\n\t\t<li><time class=\"dt-start\" datetime=\"2009-06-26T19:00+08:00\">26 July</time></li>\n\t\t<li><time class=\"dt-start\" datetime=\"2009-06-26T19:00Z\">26 July</time></li>\n\t\t<li><time class=\"dt-start\" datetime=\"2009-06-26t19:00-08:00\">26 July</time></li>\n\t\t<li><time class=\"dt-start\" datetime=\"2009-06-26 19:00:00-08:00\">26 July</time></li>\n\t</ul>\n</section>";
+ var expected = {"items":[{"type":["h-event"],"properties":{"name":["The 4th Microformat party"],"start":["2009-06-26 19:00-08:00","2009-06-26 19:00-08","2009-06-26 19:00-08:00","2009-06-26 19:00+08:00","2009-06-26 19:00+08:00","2009-06-26 19:00Z","2009-06-26 19:00-08:00","2009-06-26 19:00:00-08:00"]}}],"rels":{},"rel-urls":{}};
+
+ it('dates', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-dt-property.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-dt-property.js
new file mode 100644
index 000000000..eb97beccb
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-dt-property.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-event/dt-property
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-event', function() {
+ var htmlFragment = "<span class=\"h-event\">\n <span class=\"p-name\">The party</span> will be on \n \n <p class=\"dt-start\">\n <span class=\"value-title\" title=\"2013-03-14\"> </span>\n March 14th 2013\n </p>\n <p class=\"dt-start\">\n <time class=\"value\" datetime=\"2013-06-25\">25 July</time>, from\n <span class=\"value\">07:00:00am \n </span></p> \n \n <p>\n <time class=\"dt-start\" datetime=\"2013-06-26\">26 June</time>\n \n <ins class=\"dt-start\" datetime=\"2013-06-27\">Just added</ins>, \n <del class=\"dt-start\" datetime=\"2013-06-28\">Removed</del>\n </p>\n <abbr class=\"dt-start\" title=\"2013-06-29\">June 29</abbr> \n <data class=\"dt-start\" value=\"2013-07-01\"></data>\n <p class=\"dt-start\">2013-07-02</p>\n \n</span>";
+ var expected = {"items":[{"type":["h-event"],"properties":{"name":["The party"],"start":["2013-03-14","2013-06-25 07:00:00","2013-06-26","2013-06-27","2013-06-28","2013-06-29","2013-07-01","2013-07-02"]}}],"rels":{},"rel-urls":{}};
+
+ it('dt-property', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-justahyperlink.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-justahyperlink.js
new file mode 100644
index 000000000..26c835863
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-justahyperlink.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-event/justahyperlink
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-event', function() {
+ var htmlFragment = "<a class=\"h-event\" href=\"http://indiewebcamp.com/2012\">IndieWebCamp 2012</a>";
+ var expected = {"items":[{"type":["h-event"],"properties":{"name":["IndieWebCamp 2012"],"url":["http://indiewebcamp.com/2012"]}}],"rels":{},"rel-urls":{}};
+
+ it('justahyperlink', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-justaname.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-justaname.js
new file mode 100644
index 000000000..be3a5335d
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-justaname.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-event/justaname
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-event', function() {
+ var htmlFragment = "<p class=\"h-event\">IndieWebCamp 2012</p>";
+ var expected = {"items":[{"type":["h-event"],"properties":{"name":["IndieWebCamp 2012"]}}],"rels":{},"rel-urls":{}};
+
+ it('justaname', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-time.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-time.js
new file mode 100644
index 000000000..243b518bf
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-event-time.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-event/time
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-event', function() {
+ var htmlFragment = "<span class=\"h-event\">\n <span class=\"p-name\">The 4th Microformat party</span> will be on \n <ul>\n <li class=\"dt-start\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <time class=\"value\">19:00:00-08:00</time> \n </li>\n <li class=\"dt-start\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <time class=\"value\">19:00:00-0800</time> \n </li>\n <li class=\"dt-start\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <time class=\"value\">19:00:00+0800</time> \n </li> \n <li class=\"dt-start\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <time class=\"value\">19:00:00Z</time> \n </li>\n <li class=\"dt-start\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <time class=\"value\">19:00:00</time> \n </li>\n <li class=\"dt-start\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <time class=\"value\">19:00-08:00</time> \n </li> \n <li class=\"dt-start\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <time class=\"value\">19:00+08:00</time> \n </li>\n <li class=\"dt-start\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <time class=\"value\">19:00Z</time> \n </li>\n <li class=\"dt-start\">\n <time class=\"value\" datetime=\"2009-06-26\">26 July</time>, from\n <time class=\"value\">19:00</time> \n </li> \n <li>\n <time class=\"dt-end\" datetime=\"2013-034\">3 February 2013</time>\n </li>\n <li>\n <time class=\"dt-end\" datetime=\"2013-06-27 15:34\">26 July 2013</time>\n </li> \n </ul>\n</span>";
+ var expected = {"items":[{"type":["h-event"],"properties":{"name":["The 4th Microformat party"],"start":["2009-06-26 19:00:00-08:00","2009-06-26 19:00:00-08:00","2009-06-26 19:00:00+08:00","2009-06-26 19:00:00Z","2009-06-26 19:00:00","2009-06-26 19:00-08:00","2009-06-26 19:00+08:00","2009-06-26 19:00Z","2009-06-26 19:00"],"end":["2013-034","2013-06-27 15:34"]}}],"rels":{},"rel-urls":{}};
+
+ it('time', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-feed-implied-title.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-feed-implied-title.js
new file mode 100644
index 000000000..30bbf52df
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-feed-implied-title.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-feed/implied-title
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-feed', function() {
+ var htmlFragment = "\n<html>\n\t<head>\n\t\t<title>microformats blog</title>\n\t</head>\n\t<body>\n\t<section class=\"h-feed\">\n\t\t\n\t\t<div class=\"h-entry\">\n\t\t <h1><a class=\"p-name u-url\" href=\"http://microformats.org/2012/06/25/microformats-org-at-7\">microformats.org at 7</a></h1>\n\t\t <div class=\"e-content\">\n\t\t <p class=\"p-summary\">Last week the microformats.org community \n\t\t celebrated its 7th birthday at a gathering hosted by Mozilla in \n\t\t San Francisco and recognized accomplishments, challenges, and \n\t\t opportunities.</p>\n\t\t\n\t\t <p>The microformats tagline “humans first, machines second” \n\t\t forms the basis of many of our \n\t\t <a href=\"http://microformats.org/wiki/principles\">principles</a>, and \n\t\t in that regard, we’d like to recognize a few people and \n\t\t thank them for their years of volunteer service </p>\n\t\t </div> \n\t\t <p>Updated \n\t\t <time class=\"dt-updated\" datetime=\"2012-06-25T17:08:26\">June 25th, 2012</time>\n\t\t </p>\n\t\t</div>\n\t\t\n\t</section>\n\t</body>\n</html>";
+ var expected = {"items":[{"type":["h-feed"],"properties":{"name":["microformats blog"]},"children":[{"value":"microformats.org at 7\n\t\t \n\t\t Last week the microformats.org community \n\t\t celebrated its 7th birthday at a gathering hosted by Mozilla in \n\t\t San Francisco and recognized accomplishments, challenges, and \n\t\t opportunities.\n\t\t\n\t\t The microformats tagline “humans first, machines second” \n\t\t forms the basis of many of our \n\t\t principles, and \n\t\t in that regard, we’d like to recognize a few people and \n\t\t thank them for their years of volunteer service \n\t\t \n\t\t Updated \n\t\t June 25th, 2012","type":["h-entry"],"properties":{"name":["microformats.org at 7"],"url":["http://microformats.org/2012/06/25/microformats-org-at-7"],"content":[{"value":"Last week the microformats.org community \n\t\t celebrated its 7th birthday at a gathering hosted by Mozilla in \n\t\t San Francisco and recognized accomplishments, challenges, and \n\t\t opportunities.\n\t\t\n\t\t The microformats tagline “humans first, machines second” \n\t\t forms the basis of many of our \n\t\t principles, and \n\t\t in that regard, we’d like to recognize a few people and \n\t\t thank them for their years of volunteer service","html":"\n\t\t <p class=\"p-summary\">Last week the microformats.org community \n\t\t celebrated its 7th birthday at a gathering hosted by Mozilla in \n\t\t San Francisco and recognized accomplishments, challenges, and \n\t\t opportunities.</p>\n\t\t\n\t\t <p>The microformats tagline “humans first, machines second” \n\t\t forms the basis of many of our \n\t\t <a href=\"http://microformats.org/wiki/principles\">principles</a>, and \n\t\t in that regard, we’d like to recognize a few people and \n\t\t thank them for their years of volunteer service </p>\n\t\t "}],"summary":["Last week the microformats.org community \n\t\t celebrated its 7th birthday at a gathering hosted by Mozilla in \n\t\t San Francisco and recognized accomplishments, challenges, and \n\t\t opportunities."],"updated":["2012-06-25 17:08:26"]}}]}],"rels":{},"rel-urls":{}};
+
+ it('implied-title', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-feed-simple.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-feed-simple.js
new file mode 100644
index 000000000..c72b24140
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-feed-simple.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-feed/simple
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-feed', function() {
+ var htmlFragment = "<section class=\"h-feed\">\n\t<h1 class=\"p-name\">Microformats blog</h1>\n\t<a class=\"p-author h-card\" href=\"http://tantek.com/\">Tantek</a>\n\t<a class=\"u-url\" href=\"http://microformats.org/blog\">permlink</a>\n\t<img class=\"u-photo\" src=\"photo.jpeg\"/>\n\t\n\t<div class=\"h-entry\">\n\t <h1><a class=\"p-name u-url\" href=\"http://microformats.org/2012/06/25/microformats-org-at-7\">microformats.org at 7</a></h1>\n\t <div class=\"e-content\">\n\t <p class=\"p-summary\">Last week the microformats.org community \n\t celebrated its 7th birthday at a gathering hosted by Mozilla in \n\t San Francisco and recognized accomplishments, challenges, and \n\t opportunities.</p>\n\t\n\t <p>The microformats tagline “humans first, machines second” \n\t forms the basis of many of our \n\t <a href=\"http://microformats.org/wiki/principles\">principles</a>, and \n\t in that regard, we’d like to recognize a few people and \n\t thank them for their years of volunteer service </p>\n\t </div> \n\t <p>Updated \n\t <time class=\"dt-updated\" datetime=\"2012-06-25T17:08:26\">June 25th, 2012</time>\n\t </p>\n\t</div>\n\t\n</section>";
+ var expected = {"items":[{"type":["h-feed"],"properties":{"name":["Microformats blog"],"author":[{"value":"Tantek","type":["h-card"],"properties":{"name":["Tantek"],"url":["http://tantek.com/"]}}],"url":["http://microformats.org/blog"],"photo":["http://example.com/photo.jpeg"]},"children":[{"value":"microformats.org at 7\n\t \n\t Last week the microformats.org community \n\t celebrated its 7th birthday at a gathering hosted by Mozilla in \n\t San Francisco and recognized accomplishments, challenges, and \n\t opportunities.\n\t\n\t The microformats tagline “humans first, machines second” \n\t forms the basis of many of our \n\t principles, and \n\t in that regard, we’d like to recognize a few people and \n\t thank them for their years of volunteer service \n\t \n\t Updated \n\t June 25th, 2012","type":["h-entry"],"properties":{"name":["microformats.org at 7"],"url":["http://microformats.org/2012/06/25/microformats-org-at-7"],"content":[{"value":"Last week the microformats.org community \n\t celebrated its 7th birthday at a gathering hosted by Mozilla in \n\t San Francisco and recognized accomplishments, challenges, and \n\t opportunities.\n\t\n\t The microformats tagline “humans first, machines second” \n\t forms the basis of many of our \n\t principles, and \n\t in that regard, we’d like to recognize a few people and \n\t thank them for their years of volunteer service","html":"\n\t <p class=\"p-summary\">Last week the microformats.org community \n\t celebrated its 7th birthday at a gathering hosted by Mozilla in \n\t San Francisco and recognized accomplishments, challenges, and \n\t opportunities.</p>\n\t\n\t <p>The microformats tagline “humans first, machines second” \n\t forms the basis of many of our \n\t <a href=\"http://microformats.org/wiki/principles\">principles</a>, and \n\t in that regard, we’d like to recognize a few people and \n\t thank them for their years of volunteer service </p>\n\t "}],"summary":["Last week the microformats.org community \n\t celebrated its 7th birthday at a gathering hosted by Mozilla in \n\t San Francisco and recognized accomplishments, challenges, and \n\t opportunities."],"updated":["2012-06-25 17:08:26"]}}]}],"rels":{},"rel-urls":{}};
+
+ it('simple', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-geo-abbrpattern.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-geo-abbrpattern.js
new file mode 100644
index 000000000..d26e9ed0d
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-geo-abbrpattern.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-geo/abbrpattern
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-geo', function() {
+ var htmlFragment = "<meta charset=\"utf-8\">\n<p class=\"h-geo\">\n <abbr class=\"p-latitude\" title=\"37.408183\">N 37° 24.491</abbr>, \n <abbr class=\"p-longitude\" title=\"-122.13855\">W 122° 08.313</abbr>\n</p>";
+ var expected = {"items":[{"type":["h-geo"],"properties":{"latitude":["37.408183"],"longitude":["-122.13855"],"name":["N 37° 24.491, \n W 122° 08.313"]}}],"rels":{},"rel-urls":{}};
+
+ it('abbrpattern', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-geo-altitude.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-geo-altitude.js
new file mode 100644
index 000000000..45da683ff
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-geo-altitude.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-geo/altitude
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-geo', function() {
+ var htmlFragment = "<p>My favourite hill in the lakes is \n <span class=\"h-geo\">\n <span class=\"p-name\">Pen-y-ghent</span> \n (Geo: <span class=\"p-latitude\">54.155278</span>,\n <span class=\"p-longitude\">-2.249722</span>). It\n raises to <span class=\"p-altitude\">694</span>m.\n </span>\n</p>";
+ var expected = {"items":[{"type":["h-geo"],"properties":{"name":["Pen-y-ghent"],"latitude":["54.155278"],"longitude":["-2.249722"],"altitude":["694"]}}],"rels":{},"rel-urls":{}};
+
+ it('altitude', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-geo-hidden.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-geo-hidden.js
new file mode 100644
index 000000000..968ed1285
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-geo-hidden.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-geo/hidden
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-geo', function() {
+ var htmlFragment = "<p>\n <span class=\"h-geo\">The Bricklayer's Arms\n <span class=\"p-latitude\">\n <span class=\"value-title\" title=\"51.513458\"> </span> \n </span>\n <span class=\"p-longitude\">\n <span class=\"value-title\" title=\"-0.14812\"> </span>\n </span>\n </span>\n</p>";
+ var expected = {"items":[{"type":["h-geo"],"properties":{"latitude":["51.513458"],"longitude":["-0.14812"],"name":["The Bricklayer's Arms"]}}],"rels":{},"rel-urls":{}};
+
+ it('hidden', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-geo-justaname.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-geo-justaname.js
new file mode 100644
index 000000000..23c142462
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-geo-justaname.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-geo/justaname
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-geo', function() {
+ var htmlFragment = "<p>On my way to The Bricklayer's Arms\n (Geo: <span class=\"h-geo\">51.513458;-0.14812</span>)\n</p>";
+ var expected = {"items":[{"type":["h-geo"],"properties":{"name":["51.513458;-0.14812"]}}],"rels":{},"rel-urls":{}};
+
+ it('justaname', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-geo-simpleproperties.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-geo-simpleproperties.js
new file mode 100644
index 000000000..e9700a3e2
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-geo-simpleproperties.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-geo/simpleproperties
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-geo', function() {
+ var htmlFragment = "<p class=\"h-geo\">We are meeting at \n <span class=\"p-name\">The Bricklayer's Arms</span>\n (Geo: <span class=\"p-latitude\">51.513458</span>:\n <span class=\"p-longitude\">-0.14812</span>)\n</p>";
+ var expected = {"items":[{"type":["h-geo"],"properties":{"name":["The Bricklayer's Arms"],"latitude":["51.513458"],"longitude":["-0.14812"]}}],"rels":{},"rel-urls":{}};
+
+ it('simpleproperties', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-geo-valuetitleclass.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-geo-valuetitleclass.js
new file mode 100644
index 000000000..813d21592
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-geo-valuetitleclass.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-geo/valuetitleclass
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-geo', function() {
+ var htmlFragment = "<meta charset=\"utf-8\">\n<p>\n <span class=\"h-geo\">\n <span class=\"p-latitude\">\n <span class=\"value-title\" title=\"51.513458\">N 51° 51.345</span>, \n </span>\n <span class=\"p-longitude\">\n <span class=\"value-title\" title=\"-0.14812\">W -0° 14.812</span>\n </span>\n </span>\n</p>";
+ var expected = {"items":[{"type":["h-geo"],"properties":{"latitude":["51.513458"],"longitude":["-0.14812"],"name":["N 51° 51.345, \n \n \n W -0° 14.812"]}}],"rels":{},"rel-urls":{}};
+
+ it('valuetitleclass', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-news-all.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-news-all.js
new file mode 100644
index 000000000..a7deb3f2f
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-news-all.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-news/all
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-news', function() {
+ var htmlFragment = "<div class=\"h-news\">\n <div class=\"p-entry h-entry\">\n <h1><a class=\"p-name u-url\" href=\"http://microformats.org/2012/06/25/microformats-org-at-7\">microformats.org at 7</a></h1>\n <div class=\"e-content\">\n <p class=\"p-summary\">Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities.</p>\n\n <p>The microformats tagline “humans first, machines second” \n forms the basis of many of our \n <a href=\"http://microformats.org/wiki/principles\">principles</a>, and \n in that regard, we’d like to recognize a few people and \n thank them for their years of volunteer service </p>\n </div> \n <p>Updated \n <time class=\"dt-updated\" datetime=\"2012-06-25T17:08:26\">June 25th, 2012</time> by\n <a class=\"p-author h-card\" href=\"http://tantek.com/\">Tantek</a>\n </p>\n </div>\n\n <p>\n <span class=\"p-dateline h-adr\">\n <span class=\"p-locality\">San Francisco</span>, \n <span class=\"p-region\">CA</span> \n </span>\n (Geo: <span class=\"p-geo\">37.774921;-122.445202</span>) \n <span class=\"p-source-org h-card\">\n <a class=\"p-name u-url\" href=\"http://microformats.org/\">microformats.org</a>\n </span>\n </p>\n <p>\n <a class=\"u-principles\" href=\"http://microformats.org/wiki/Category:public_domain_license\">Publishing policy</a>\n </p>\n</div>";
+ var expected = {"items":[{"type":["h-news"],"properties":{"entry":[{"value":"microformats.org at 7","type":["h-entry"],"properties":{"name":["microformats.org at 7"],"url":["http://microformats.org/2012/06/25/microformats-org-at-7"],"content":[{"value":"Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities.\n\n The microformats tagline “humans first, machines second” \n forms the basis of many of our \n principles, and \n in that regard, we’d like to recognize a few people and \n thank them for their years of volunteer service","html":"\n <p class=\"p-summary\">Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities.</p>\n\n <p>The microformats tagline “humans first, machines second” \n forms the basis of many of our \n <a href=\"http://microformats.org/wiki/principles\">principles</a>, and \n in that regard, we’d like to recognize a few people and \n thank them for their years of volunteer service </p>\n "}],"summary":["Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities."],"updated":["2012-06-25 17:08:26"],"author":[{"value":"Tantek","type":["h-card"],"properties":{"name":["Tantek"],"url":["http://tantek.com/"]}}]}}],"dateline":[{"value":"San Francisco, \n CA","type":["h-adr"],"properties":{"locality":["San Francisco"],"region":["CA"],"name":["San Francisco, \n CA"]}}],"geo":["37.774921;-122.445202"],"source-org":[{"value":"microformats.org","type":["h-card"],"properties":{"name":["microformats.org"],"url":["http://microformats.org/"]}}],"principles":["http://microformats.org/wiki/Category:public_domain_license"],"name":["microformats.org at 7\n \n Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities.\n\n The microformats tagline “humans first, machines second” \n forms the basis of many of our \n principles, and \n in that regard, we’d like to recognize a few people and \n thank them for their years of volunteer service \n \n Updated \n June 25th, 2012 by\n Tantek\n \n \n\n \n \n San Francisco, \n CA \n \n (Geo: 37.774921;-122.445202) \n \n microformats.org\n \n \n \n Publishing policy"]}}],"rels":{},"rel-urls":{}};
+
+ it('all', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-news-minimum.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-news-minimum.js
new file mode 100644
index 000000000..4494cb8ab
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-news-minimum.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-news/minimum
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-news', function() {
+ var htmlFragment = "<div class=\"h-news\">\n <div class=\"p-entry h-entry\">\n <h1><a class=\"p-name u-url\" href=\"http://microformats.org/2012/06/25/microformats-org-at-7\">microformats.org at 7</a></h1>\n <div class=\"e-content\">\n <p class=\"p-summary\">Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities.</p>\n\n <p>The microformats tagline “humans first, machines second” \n forms the basis of many of our \n <a href=\"http://microformats.org/wiki/principles\">principles</a>, and \n in that regard, we’d like to recognize a few people and \n thank them for their years of volunteer service </p>\n </div> \n <p>Updated \n <time class=\"dt-updated\" datetime=\"2012-06-25T17:08:26\">June 25th, 2012</time> by\n <a class=\"p-author h-card\" href=\"http://tantek.com/\">Tantek</a>\n </p>\n </div>\n <p>\n <a class=\"p-source-org h-card\" href=\"http://microformats.org/\">microformats.org</a> \n </p>\n</div>";
+ var expected = {"items":[{"type":["h-news"],"properties":{"entry":[{"value":"microformats.org at 7","type":["h-entry"],"properties":{"name":["microformats.org at 7"],"url":["http://microformats.org/2012/06/25/microformats-org-at-7"],"content":[{"value":"Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities.\n\n The microformats tagline “humans first, machines second” \n forms the basis of many of our \n principles, and \n in that regard, we’d like to recognize a few people and \n thank them for their years of volunteer service","html":"\n <p class=\"p-summary\">Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities.</p>\n\n <p>The microformats tagline “humans first, machines second” \n forms the basis of many of our \n <a href=\"http://microformats.org/wiki/principles\">principles</a>, and \n in that regard, we’d like to recognize a few people and \n thank them for their years of volunteer service </p>\n "}],"summary":["Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities."],"updated":["2012-06-25 17:08:26"],"author":[{"value":"Tantek","type":["h-card"],"properties":{"name":["Tantek"],"url":["http://tantek.com/"]}}]}}],"source-org":[{"value":"microformats.org","type":["h-card"],"properties":{"name":["microformats.org"],"url":["http://microformats.org/"]}}],"name":["microformats.org at 7\n \n Last week the microformats.org community \n celebrated its 7th birthday at a gathering hosted by Mozilla in \n San Francisco and recognized accomplishments, challenges, and \n opportunities.\n\n The microformats tagline “humans first, machines second” \n forms the basis of many of our \n principles, and \n in that regard, we’d like to recognize a few people and \n thank them for their years of volunteer service \n \n Updated \n June 25th, 2012 by\n Tantek\n \n \n \n microformats.org"]}}],"rels":{},"rel-urls":{}};
+
+ it('minimum', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-org-hyperlink.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-org-hyperlink.js
new file mode 100644
index 000000000..b7150aae4
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-org-hyperlink.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-org/hyperlink
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-org', function() {
+ var htmlFragment = "<a class=\"h-org\" href=\"http://mozilla.org/\">Mozilla Foundation</a>";
+ var expected = {"items":[{"type":["h-org"],"properties":{"name":["Mozilla Foundation"],"url":["http://mozilla.org/"]}}],"rels":{},"rel-urls":{}};
+
+ it('hyperlink', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-org-simple.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-org-simple.js
new file mode 100644
index 000000000..4f5a75e88
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-org-simple.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-org/simple
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-org', function() {
+ var htmlFragment = "<span class=\"h-org\">Mozilla Foundation</span>";
+ var expected = {"items":[{"type":["h-org"],"properties":{"name":["Mozilla Foundation"]}}],"rels":{},"rel-urls":{}};
+
+ it('simple', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-org-simpleproperties.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-org-simpleproperties.js
new file mode 100644
index 000000000..5c7e939e6
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-org-simpleproperties.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-org/simpleproperties
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-org', function() {
+ var htmlFragment = "<p class=\"h-org\">\n <span class=\"p-organization-name\">W3C</span> - \n <span class=\"p-organization-unit\">CSS Working Group</span>\n</p>";
+ var expected = {"items":[{"type":["h-org"],"properties":{"organization-name":["W3C"],"organization-unit":["CSS Working Group"],"name":["W3C - \n CSS Working Group"]}}],"rels":{},"rel-urls":{}};
+
+ it('simpleproperties', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-product-aggregate.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-product-aggregate.js
new file mode 100644
index 000000000..b07d3f547
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-product-aggregate.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-product/aggregate
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-product', function() {
+ var htmlFragment = "<meta charset=\"utf-8\">\n<div class=\"h-product\">\n <h2 class=\"p-name\">Raspberry Pi</h2>\n <img class=\"u-photo\" src=\"http://upload.wikimedia.org/wikipedia/commons/thumb/3/3d/RaspberryPi.jpg/320px-RaspberryPi.jpg\" />\n <p class=\"e-description\">The Raspberry Pi is a credit-card sized computer that plugs into your TV and a keyboard. It’s a capable little PC which can be used for many of the things that your desktop PC does, like spreadsheets, word-processing and games. It also plays high-definition video. We want to see it being used by kids all over the world to learn programming.</p>\n <a class=\"u-url\" href=\"http://www.raspberrypi.org/\">More info about the Raspberry Pi</a>\n <p class=\"p-price\">£29.95</p>\n <p class=\"p-review h-review-aggregate\">\n <span class=\"p-rating h-rating\">\n <span class=\"p-average\">9.2</span> out of \n <span class=\"p-best\">10</span> \n based on <span class=\"p-count\">178</span> reviews\n </span>\n </p>\n <p>Categories: <span class=\"p-category\">Computer</span>, <span class=\"p-category\">Education</span></p>\n <p class=\"p-brand h-card\">From: \n <span class=\"p-name p-org\">The Raspberry Pi Foundation</span> - \n <span class=\"p-locality\">Cambridge</span> \n <span class=\"p-country-name\">UK</span>\n </p>\n</div>";
+ var expected = {"items":[{"type":["h-product"],"properties":{"name":["Raspberry Pi"],"photo":["http://upload.wikimedia.org/wikipedia/commons/thumb/3/3d/RaspberryPi.jpg/320px-RaspberryPi.jpg"],"description":[{"value":"The Raspberry Pi is a credit-card sized computer that plugs into your TV and a keyboard. It’s a capable little PC which can be used for many of the things that your desktop PC does, like spreadsheets, word-processing and games. It also plays high-definition video. We want to see it being used by kids all over the world to learn programming.","html":"The Raspberry Pi is a credit-card sized computer that plugs into your TV and a keyboard. It’s a capable little PC which can be used for many of the things that your desktop PC does, like spreadsheets, word-processing and games. It also plays high-definition video. We want to see it being used by kids all over the world to learn programming."}],"url":["http://www.raspberrypi.org/"],"price":["£29.95"],"review":[{"value":"9.2 out of \n 10 \n based on 178 reviews","type":["h-review-aggregate"],"properties":{"rating":[{"value":"9.2 out of \n 10 \n based on 178 reviews","type":["h-rating"],"properties":{"average":["9.2"],"best":["10"],"count":["178"],"name":["9.2 out of \n 10 \n based on 178 reviews"]}}],"name":["9.2 out of \n 10 \n based on 178 reviews"]}}],"category":["Computer","Education"],"brand":[{"value":"The Raspberry Pi Foundation","type":["h-card"],"properties":{"name":["The Raspberry Pi Foundation"],"org":["The Raspberry Pi Foundation"],"locality":["Cambridge"],"country-name":["UK"]}}]}}],"rels":{},"rel-urls":{}};
+
+ it('aggregate', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-product-justahyperlink.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-product-justahyperlink.js
new file mode 100644
index 000000000..cf2638e31
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-product-justahyperlink.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-product/justahyperlink
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-product', function() {
+ var htmlFragment = "<a class=\"h-product\" href=\"http://www.raspberrypi.org/\">Raspberry Pi</a>";
+ var expected = {"items":[{"type":["h-product"],"properties":{"name":["Raspberry Pi"],"url":["http://www.raspberrypi.org/"]}}],"rels":{},"rel-urls":{}};
+
+ it('justahyperlink', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-product-justaname.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-product-justaname.js
new file mode 100644
index 000000000..f946a10e0
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-product-justaname.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-product/justaname
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-product', function() {
+ var htmlFragment = "<p class=\"h-product\">Raspberry Pi</p>";
+ var expected = {"items":[{"type":["h-product"],"properties":{"name":["Raspberry Pi"]}}],"rels":{},"rel-urls":{}};
+
+ it('justaname', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-product-simpleproperties.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-product-simpleproperties.js
new file mode 100644
index 000000000..1c5467d51
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-product-simpleproperties.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-product/simpleproperties
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-product', function() {
+ var htmlFragment = "<meta charset=\"utf-8\">\n<div class=\"h-product\">\n <h2 class=\"p-name\">Raspberry Pi</h2>\n <img class=\"u-photo\" src=\"http://upload.wikimedia.org/wikipedia/commons/thumb/3/3d/RaspberryPi.jpg/320px-RaspberryPi.jpg\" />\n <p class=\"e-description\">The Raspberry Pi is a credit-card sized computer that plugs into your TV and a keyboard. It’s a capable little PC which can be used for many of the things that your desktop PC does, like spreadsheets, word-processing and games. It also plays high-definition video. We want to see it being used by kids all over the world to learn programming.</p>\n <a class=\"u-url\" href=\"http://www.raspberrypi.org/\">More info about the Raspberry Pi</a>\n <p class=\"p-price\">£29.95</p>\n <p class=\"p-review h-review\"><span class=\"p-rating\">4.5</span> out of 5</p>\n <p>Categories: <span class=\"p-category\">Computer</span>, <span class=\"p-category\">Education</span></p>\n</div>";
+ var expected = {"items":[{"type":["h-product"],"properties":{"name":["Raspberry Pi"],"photo":["http://upload.wikimedia.org/wikipedia/commons/thumb/3/3d/RaspberryPi.jpg/320px-RaspberryPi.jpg"],"description":[{"value":"The Raspberry Pi is a credit-card sized computer that plugs into your TV and a keyboard. It’s a capable little PC which can be used for many of the things that your desktop PC does, like spreadsheets, word-processing and games. It also plays high-definition video. We want to see it being used by kids all over the world to learn programming.","html":"The Raspberry Pi is a credit-card sized computer that plugs into your TV and a keyboard. It’s a capable little PC which can be used for many of the things that your desktop PC does, like spreadsheets, word-processing and games. It also plays high-definition video. We want to see it being used by kids all over the world to learn programming."}],"url":["http://www.raspberrypi.org/"],"price":["£29.95"],"category":["Computer","Education"],"review":[{"value":"4.5 out of 5","type":["h-review"],"properties":{"rating":["4.5"],"name":["4.5 out of 5"]}}]}}],"rels":{},"rel-urls":{}};
+
+ it('simpleproperties', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-recipe-all.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-recipe-all.js
new file mode 100644
index 000000000..fa0e4cb37
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-recipe-all.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-recipe/all
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-recipe', function() {
+ var htmlFragment = "<section class=\"h-recipe\">\n <h1 class=\"p-name\">Yorkshire Puddings</h1> \n <p class=\"p-summary\">Makes <span class=\"p-yield\">6 good sized Yorkshire puddings</span>, the way my mum taught me</p>\n\n\n <p><img class=\"u-photo\" src=\"http://codebits.glennjones.net/semantic/yorkshire-puddings.jpg\" /></p>\n\n <span class=\"p-review h-review-aggregate\">\n <span class=\"p-rating\">\n <span class=\"p-average\">4.5</span> stars out 5 based on </span>\n <span class=\"p-count\">35</span> reviews</span>\n \n \n\n <div id=\"ingredients-container\">\n <h3>Ingredients</h3>\n <ul>\n <li class=\"e-ingredient\">1 egg</li>\n <li class=\"e-ingredient\">75g plain flour</li>\n <li class=\"e-ingredient\">70ml milk</li>\n <li class=\"e-ingredient\">60ml water</li>\n <li class=\"e-ingredient\">Pinch of salt</li>\n </ul>\n </div>\n\n <h3>Time</h3>\n <ul>\n <li class=\"prepTime\">Preparation <span class=\"value-title\" title=\"PT0H10M\">10 mins</span></li>\n <li class=\"cookTime\">Cook <span class=\"value-title\" title=\"PT0H25M\">25 mins</span></li>\n </ul> \n\n\n <h3>Instructions</h3>\n <div class=\"e-instructions\">\n <ol>\n <li>Pre-heat oven to 230C or gas mark 8. Pour the vegetable oil evenly into 2 x 4-hole \n Yorkshire pudding tins and place in the oven to heat through.</li> \n \n <li>To make the batter, add all the flour into a bowl and beat in the eggs until smooth. \n Gradually add the milk and water while beating the mixture. It should be smooth and \n without lumps. Finally add a pinch of salt.</li>\n \n <li>Make sure the oil is piping hot before pouring the batter evenly into the tins. \n Place in the oven for 20-25 minutes until pudding have risen and look golden brown</li>\n </ol>\n </div>\n\n <h3>Nutrition</h3>\n <ul id=\"nutrition-list\">\n <li class=\"p-nutrition\">Calories: <span class=\"calories\">125</span></li>\n <li class=\"p-nutrition\">Fat: <span class=\"fat\">3.2g</span></li>\n <li class=\"p-nutrition\">Cholesterol: <span class=\"cholesterol\">77mg</span></li>\n </ul>\n <p>(Amount per pudding)</p>\n\n <p>\n Published on <time class=\"dt-published\" datetime=\"2011-10-27\">27 Oct 2011</time> by \n <span class=\"p-author h-card\">\n <a class=\"p-name u-url\" href=\"http://glennjones.net\">Glenn Jones</a>\n </span>\n </p>\n <a href=\"http://www.flickr.com/photos/dithie/4106528495/\">Photo by dithie</a>\n </section>";
+ var expected = {"items":[{"type":["h-recipe"],"properties":{"name":["Yorkshire Puddings"],"summary":["Makes 6 good sized Yorkshire puddings, the way my mum taught me"],"yield":["6 good sized Yorkshire puddings"],"photo":["http://codebits.glennjones.net/semantic/yorkshire-puddings.jpg"],"review":[{"value":"4.5 stars out 5 based on \n 35 reviews","type":["h-review-aggregate"],"properties":{"rating":["4.5 stars out 5 based on"],"average":["4.5"],"count":["35"],"name":["4.5 stars out 5 based on \n 35 reviews"]}}],"ingredient":[{"value":"1 egg","html":"1 egg"},{"value":"75g plain flour","html":"75g plain flour"},{"value":"70ml milk","html":"70ml milk"},{"value":"60ml water","html":"60ml water"},{"value":"Pinch of salt","html":"Pinch of salt"}],"instructions":[{"value":"Pre-heat oven to 230C or gas mark 8. Pour the vegetable oil evenly into 2 x 4-hole \n Yorkshire pudding tins and place in the oven to heat through. \n \n To make the batter, add all the flour into a bowl and beat in the eggs until smooth. \n Gradually add the milk and water while beating the mixture. It should be smooth and \n without lumps. Finally add a pinch of salt.\n \n Make sure the oil is piping hot before pouring the batter evenly into the tins. \n Place in the oven for 20-25 minutes until pudding have risen and look golden brown","html":"\n <ol>\n <li>Pre-heat oven to 230C or gas mark 8. Pour the vegetable oil evenly into 2 x 4-hole \n Yorkshire pudding tins and place in the oven to heat through.</li> \n \n <li>To make the batter, add all the flour into a bowl and beat in the eggs until smooth. \n Gradually add the milk and water while beating the mixture. It should be smooth and \n without lumps. Finally add a pinch of salt.</li>\n \n <li>Make sure the oil is piping hot before pouring the batter evenly into the tins. \n Place in the oven for 20-25 minutes until pudding have risen and look golden brown</li>\n </ol>\n "}],"nutrition":["Calories: 125","Fat: 3.2g","Cholesterol: 77mg"],"published":["2011-10-27"],"author":[{"value":"Glenn Jones","type":["h-card"],"properties":{"name":["Glenn Jones"],"url":["http://glennjones.net"]}}],"url":["http://www.flickr.com/photos/dithie/4106528495/"]}}],"rels":{},"rel-urls":{}};
+
+ it('all', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-recipe-minimum.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-recipe-minimum.js
new file mode 100644
index 000000000..ac3d91dc7
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-recipe-minimum.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-recipe/minimum
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-recipe', function() {
+ var htmlFragment = "<div class=\"h-recipe\"> \n <p class=\"p-name\">Toast</p>\n <ul>\n <li class=\"e-ingredient\">Slice of bread</li>\n <li class=\"e-ingredient\">Butter</li>\n </ul>\n</div>";
+ var expected = {"items":[{"type":["h-recipe"],"properties":{"name":["Toast"],"ingredient":[{"value":"Slice of bread","html":"Slice of bread"},{"value":"Butter","html":"Butter"}]}}],"rels":{},"rel-urls":{}};
+
+ it('minimum', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-resume-affiliation.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-resume-affiliation.js
new file mode 100644
index 000000000..73329d46c
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-resume-affiliation.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-resume/affiliation
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-resume', function() {
+ var htmlFragment = "<div class=\"h-resume\">\n <p>\n <span class=\"p-name\">Tim Berners-Lee</span>, \n <span class=\"p-summary\">invented the World Wide Web</span>. \n </p> \n Belongs to following groups:\n <p> \n <a class=\"p-affiliation h-card\" href=\"http://www.w3.org/\">\n <img class=\"p-name u-photo\" alt=\"W3C\" src=\"http://www.w3.org/Icons/WWW/w3c_home_nb.png\" />\n </a>\n </p> \n</div>";
+ var expected = {"items":[{"type":["h-resume"],"properties":{"name":["Tim Berners-Lee"],"summary":["invented the World Wide Web"],"affiliation":[{"type":["h-card"],"properties":{"name":["W3C"],"photo":["http://www.w3.org/Icons/WWW/w3c_home_nb.png"],"url":["http://www.w3.org/"]}}]}}],"rels":{},"rel-urls":{}};
+
+ it('affiliation', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-resume-contact.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-resume-contact.js
new file mode 100644
index 000000000..f2a1f76f7
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-resume-contact.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-resume/contact
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-resume', function() {
+ var htmlFragment = "<div class=\"h-resume\">\n <p class=\"p-name\">Tim Berners-Lee</p>\n <p class=\"p-summary\">Invented the World Wide Web.</p><hr />\n <div class=\"p-contact h-card\">\n <p class=\"p-name\">MIT</p>\n <p>\n <span class=\"p-street-address\">32 Vassar Street</span>, \n <span class=\"p-extended-address\">Room 32-G524</span>, \n <span class=\"p-locality\">Cambridge</span>, \n <span class=\"p-region\">MA</span> \n <span class=\"p-postal-code\">02139</span>, \n <span class=\"p-country-name\">USA</span>.\n </p>\n <p>Tel:<span class=\"p-tel\">+1 (617) 253 5702</span></p>\n <p>Email:<a class=\"u-email\" href=\"mailto:timbl@w3.org\">timbl@w3.org</a></p>\n </div>\n</div>";
+ var expected = {"items":[{"type":["h-resume"],"properties":{"name":["Tim Berners-Lee"],"summary":["Invented the World Wide Web."],"contact":[{"value":"MIT","type":["h-card"],"properties":{"name":["MIT"],"street-address":["32 Vassar Street"],"extended-address":["Room 32-G524"],"locality":["Cambridge"],"region":["MA"],"postal-code":["02139"],"country-name":["USA"],"tel":["+1 (617) 253 5702"],"email":["mailto:timbl@w3.org"]}}]}}],"rels":{},"rel-urls":{}};
+
+ it('contact', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-resume-education.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-resume-education.js
new file mode 100644
index 000000000..5e3838434
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-resume-education.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-resume/education
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-resume', function() {
+ var htmlFragment = "<div class=\"h-resume\">\n <p class=\"p-name\">Tim Berners-Lee</p>\n <div class=\"p-contact h-card\">\n <p class=\"p-title\">Director of the World Wide Web Foundation</p>\n </div>\n <p class=\"p-summary\">Invented the World Wide Web.</p><hr />\n <p class=\"p-education h-event h-card\">\n <span class=\"p-name p-org\">The Queen's College, Oxford University</span>, \n <span class=\"p-description\">BA Hons (I) Physics</span> \n <time class=\"dt-start\" datetime=\"1973-09\">1973</time> –\n <time class=\"dt-end\" datetime=\"1976-06\">1976</time>\n </p>\n</div>";
+ var expected = {"items":[{"type":["h-resume"],"properties":{"name":["Tim Berners-Lee"],"contact":[{"value":"Director of the World Wide Web Foundation","type":["h-card"],"properties":{"title":["Director of the World Wide Web Foundation"],"name":["Director of the World Wide Web Foundation"]}}],"summary":["Invented the World Wide Web."],"education":[{"value":"The Queen's College, Oxford University","type":["h-event","h-card"],"properties":{"name":["The Queen's College, Oxford University"],"org":["The Queen's College, Oxford University"],"description":["BA Hons (I) Physics"],"start":["1973-09"],"end":["1976-06"]}}]}}],"rels":{},"rel-urls":{}};
+
+ it('education', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-resume-justaname.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-resume-justaname.js
new file mode 100644
index 000000000..2357bf1a2
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-resume-justaname.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-resume/justaname
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-resume', function() {
+ var htmlFragment = "<p class=\"h-resume\">Tim Berners-Lee, invented the World Wide Web.</p>";
+ var expected = {"items":[{"type":["h-resume"],"properties":{"name":["Tim Berners-Lee, invented the World Wide Web."]}}],"rels":{},"rel-urls":{}};
+
+ it('justaname', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-resume-skill.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-resume-skill.js
new file mode 100644
index 000000000..60a983e04
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-resume-skill.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-resume/skill
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-resume', function() {
+ var htmlFragment = "<div class=\"h-resume\">\n <p>\n <span class=\"p-name\">Tim Berners-Lee</span>, \n <span class=\"p-summary\">invented the World Wide Web</span>.\n </p>\n Skills: \n <ul>\n <li class=\"p-skill\">information systems</li>\n <li class=\"p-skill\">advocacy</li>\n <li class=\"p-skill\">leadership</li>\n <ul> \n</ul></ul></div>";
+ var expected = {"items":[{"type":["h-resume"],"properties":{"name":["Tim Berners-Lee"],"summary":["invented the World Wide Web"],"skill":["information systems","advocacy","leadership"]}}],"rels":{},"rel-urls":{}};
+
+ it('skill', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-resume-work.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-resume-work.js
new file mode 100644
index 000000000..d61ea3de5
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-resume-work.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-resume/work
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-resume', function() {
+ var htmlFragment = "<meta charset=\"utf-8\">\n<div class=\"h-resume\">\n <p class=\"p-name\">Tim Berners-Lee</p>\n <div class=\"p-contact h-card\">\n <p class=\"p-title\">Director of the World Wide Web Foundation</p>\n </div>\n <p class=\"p-summary\">Invented the World Wide Web.</p><hr />\n <div class=\"p-experience h-event h-card\">\n <p class=\"p-title\">Director</p>\n <p><a class=\"p-name p-org u-url\" href=\"http://www.webfoundation.org/\">World Wide Web Foundation</a></p>\n <p>\n <time class=\"dt-start\" datetime=\"2009-01-18\">Jan 2009</time> – Present\n <time class=\"dt-duration\" datetime=\"P2Y11M\">(2 years 11 month)</time>\n </p>\n </div>\n</div>";
+ var expected = {"items":[{"type":["h-resume"],"properties":{"name":["Tim Berners-Lee"],"contact":[{"value":"Director of the World Wide Web Foundation","type":["h-card"],"properties":{"title":["Director of the World Wide Web Foundation"],"name":["Director of the World Wide Web Foundation"]}}],"summary":["Invented the World Wide Web."],"experience":[{"value":"World Wide Web Foundation","type":["h-event","h-card"],"properties":{"title":["Director"],"name":["World Wide Web Foundation"],"org":["World Wide Web Foundation"],"url":["http://www.webfoundation.org/"],"start":["2009-01-18"],"duration":["P2Y11M"]}}]}}],"rels":{},"rel-urls":{}};
+
+ it('work', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-aggregate-hevent.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-aggregate-hevent.js
new file mode 100644
index 000000000..e698ee37a
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-aggregate-hevent.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-review-aggregate/hevent
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-review-aggregate', function() {
+ var htmlFragment = "<div class=\"h-review-aggregate\">\n <div class=\"p-item h-event\">\n <h3 class=\"p-name\">Fullfrontal</h3>\n <p class=\"p-description\">A one day JavaScript Conference held in Brighton</p>\n <p><time class=\"dt-start\" datetime=\"2012-11-09\">9th November 2012</time></p> \n </div> \n \n <p class=\"p-rating\">\n <span class=\"p-average value\">9.9</span> out of \n <span class=\"p-best\">10</span> \n based on <span class=\"p-count\">62</span> reviews\n </p>\n</div>";
+ var expected = {"items":[{"type":["h-review-aggregate"],"properties":{"item":[{"value":"Fullfrontal","type":["h-event"],"properties":{"name":["Fullfrontal"],"description":["A one day JavaScript Conference held in Brighton"],"start":["2012-11-09"]}}],"rating":["9.9"],"average":["9.9"],"best":["10"],"count":["62"],"name":["Fullfrontal\n A one day JavaScript Conference held in Brighton\n 9th November 2012 \n \n \n \n 9.9 out of \n 10 \n based on 62 reviews"]}}],"rels":{},"rel-urls":{}};
+
+ it('hevent', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-aggregate-justahyperlink.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-aggregate-justahyperlink.js
new file mode 100644
index 000000000..729fdfb2d
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-aggregate-justahyperlink.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-review-aggregate/justahyperlink
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-review-aggregate', function() {
+ var htmlFragment = "<div class=\"h-review-aggregate\">\n <h3 class=\"p-item h-item\">Mediterranean Wraps</h3>\n <span class=\"p-summary\">\n Customers flock to this small restaurant for their \n tasty falafel and shawerma wraps and welcoming staff.\n </span>\n <span class=\"p-rating\">4.5</span> out of 5 \n</div>";
+ var expected = {"items":[{"type":["h-review-aggregate"],"properties":{"item":[{"value":"Mediterranean Wraps","type":["h-item"],"properties":{"name":["Mediterranean Wraps"]}}],"summary":["Customers flock to this small restaurant for their \n tasty falafel and shawerma wraps and welcoming staff."],"rating":["4.5"],"name":["Mediterranean Wraps\n \n Customers flock to this small restaurant for their \n tasty falafel and shawerma wraps and welcoming staff.\n \n 4.5 out of 5"]}}],"rels":{},"rel-urls":{}};
+
+ it('justahyperlink', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-aggregate-simpleproperties.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-aggregate-simpleproperties.js
new file mode 100644
index 000000000..d49cabb5f
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-aggregate-simpleproperties.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-review-aggregate/simpleproperties
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-review-aggregate', function() {
+ var htmlFragment = "<div class=\"h-review-aggregate\">\n <div class=\"p-item h-card\">\n <h3 class=\"p-name\">Mediterranean Wraps</h3>\n <p>\n <span class=\"p-street-address\">433 S California Ave</span>, \n <span class=\"p-locality\">Palo Alto</span>, \n <span class=\"p-region\">CA</span> - \n <span class=\"p-tel\">(650) 321-8189</span>\n </p>\n </div> \n <span class=\"p-summary\">Customers flock to this small restaurant for their \n tasty falafel and shawerma wraps and welcoming staff.</span>\n <span class=\"p-rating\">\n <span class=\"p-average value\">9.2</span> out of \n <span class=\"p-best\">10</span> \n based on <span class=\"p-count\">17</span> reviews\n </span>\n</div>";
+ var expected = {"items":[{"type":["h-review-aggregate"],"properties":{"item":[{"value":"Mediterranean Wraps","type":["h-card"],"properties":{"name":["Mediterranean Wraps"],"street-address":["433 S California Ave"],"locality":["Palo Alto"],"region":["CA"],"tel":["(650) 321-8189"]}}],"summary":["Customers flock to this small restaurant for their \n tasty falafel and shawerma wraps and welcoming staff."],"rating":["9.2"],"average":["9.2"],"best":["10"],"count":["17"],"name":["Mediterranean Wraps\n \n 433 S California Ave, \n Palo Alto, \n CA - \n (650) 321-8189\n \n \n Customers flock to this small restaurant for their \n tasty falafel and shawerma wraps and welcoming staff.\n \n 9.2 out of \n 10 \n based on 17 reviews"]}}],"rels":{},"rel-urls":{}};
+
+ it('simpleproperties', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-hyperlink.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-hyperlink.js
new file mode 100644
index 000000000..3f547d7a9
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-hyperlink.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-review/hyperlink
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-review', function() {
+ var htmlFragment = "<a class=\"h-review\" href=\"https://plus.google.com/116941523817079328322/about\">Crepes on Cole</a>";
+ var expected = {"items":[{"type":["h-review"],"properties":{"name":["Crepes on Cole"],"url":["https://plus.google.com/116941523817079328322/about"]}}],"rels":{},"rel-urls":{}};
+
+ it('hyperlink', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-implieditem.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-implieditem.js
new file mode 100644
index 000000000..ecde19277
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-implieditem.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-review/implieditem
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-review', function() {
+ var htmlFragment = "<div class=\"h-review\">\n <a class=\"p-item h-item\" href=\"http://example.com/crepeoncole\">Crepes on Cole</a>\n <p><span class=\"p-rating\">4.7</span> out of 5 stars</p>\n</div>";
+ var expected = {"items":[{"type":["h-review"],"properties":{"item":[{"value":"Crepes on Cole","type":["h-item"],"properties":{"name":["Crepes on Cole"],"url":["http://example.com/crepeoncole"]}}],"rating":["4.7"],"name":["Crepes on Cole\n 4.7 out of 5 stars"]}}],"rels":{},"rel-urls":{}};
+
+ it('implieditem', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-item.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-item.js
new file mode 100644
index 000000000..d8aef51c8
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-item.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-review/item
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-review', function() {
+ var htmlFragment = "<base href=\"http://example.com\" >\n<div class=\"h-review\">\n <p class=\"p-item h-item\">\n <img class=\"u-photo\" src=\"images/photo.gif\" />\n <a class=\"p-name u-url\" href=\"http://example.com/crepeoncole\">Crepes on Cole</a>\n </p>\n <p><span class=\"p-rating\">5</span> out of 5 stars</p>\n</div>";
+ var expected = {"items":[{"type":["h-review"],"properties":{"item":[{"value":"Crepes on Cole","type":["h-item"],"properties":{"photo":["http://example.com/images/photo.gif"],"name":["Crepes on Cole"],"url":["http://example.com/crepeoncole"]}}],"rating":["5"],"name":["Crepes on Cole\n \n 5 out of 5 stars"]}}],"rels":{},"rel-urls":{}};
+
+ it('item', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-justaname.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-justaname.js
new file mode 100644
index 000000000..89523e909
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-justaname.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-review/justaname
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-review', function() {
+ var htmlFragment = "<p class=\"h-review\">Crepes on Cole</p>";
+ var expected = {"items":[{"type":["h-review"],"properties":{"name":["Crepes on Cole"]}}],"rels":{},"rel-urls":{}};
+
+ it('justaname', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-photo.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-photo.js
new file mode 100644
index 000000000..ee0c41fe6
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-photo.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-review/photo
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-review', function() {
+ var htmlFragment = "<base href=\"http://example.com\" ><img class=\"h-review\" src=\"images/photo.gif\" alt=\"Crepes on Cole\" />";
+ var expected = {"items":[{"type":["h-review"],"properties":{"name":["Crepes on Cole"],"photo":["http://example.com/images/photo.gif"]}}],"rels":{},"rel-urls":{}};
+
+ it('photo', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-vcard.js b/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-vcard.js
new file mode 100644
index 000000000..8411c4d2a
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-h-review-vcard.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/h-review/vcard
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('h-review', function() {
+ var htmlFragment = "<div class=\"h-review\">\n <span><span class=\"p-rating\">5</span> out of 5 stars</span>\n <h4 class=\"p-name\">Crepes on Cole is awesome</h4>\n <span class=\"p-reviewer h-card\">\n Reviewer: <span class=\"p-name\">Tantek</span> - \n </span>\n <time class=\"dt-reviewed\" datetime=\"2005-04-18\">April 18, 2005</time>\n <div class=\"e-description\">\n <p class=\"p-item h-card\">\n <span class=\"p-name p-org\">Crepes on Cole</span> is one of the best little \n creperies in <span class=\"p-adr h-adr\"><span class=\"p-locality\">San Francisco</span></span>.\n Excellent food and service. Plenty of tables in a variety of sizes \n for parties large and small. Window seating makes for excellent \n people watching to/from the N-Judah which stops right outside. \n I've had many fun social gatherings here, as well as gotten \n plenty of work done thanks to neighborhood WiFi.\n </p>\n </div>\n <p>Visit date: <span>April 2005</span></p>\n <p>Food eaten: <a class=\"p-category\" href=\"http://en.wikipedia.org/wiki/crepe\">crepe</a></p>\n <p>Permanent link for review: <a class=\"u-url\" href=\"http://example.com/crepe\">http://example.com/crepe</a></p>\n <p><a rel=\"license\" href=\"http://en.wikipedia.org/wiki/Wikipedia:Text_of_Creative_Commons_Attribution-ShareAlike_3.0_Unported_License\">Creative Commons Attribution-ShareAlike License</a></p>\n</div>";
+ var expected = {"items":[{"type":["h-review"],"properties":{"rating":["5"],"name":["Crepes on Cole is awesome"],"reviewer":[{"value":"Tantek","type":["h-card"],"properties":{"name":["Tantek"]}}],"reviewed":["2005-04-18"],"description":[{"value":"Crepes on Cole is one of the best little \n creperies in San Francisco.\n Excellent food and service. Plenty of tables in a variety of sizes \n for parties large and small. Window seating makes for excellent \n people watching to/from the N-Judah which stops right outside. \n I've had many fun social gatherings here, as well as gotten \n plenty of work done thanks to neighborhood WiFi.","html":"\n <p class=\"p-item h-card\">\n <span class=\"p-name p-org\">Crepes on Cole</span> is one of the best little \n creperies in <span class=\"p-adr h-adr\"><span class=\"p-locality\">San Francisco</span></span>.\n Excellent food and service. Plenty of tables in a variety of sizes \n for parties large and small. Window seating makes for excellent \n people watching to/from the N-Judah which stops right outside. \n I've had many fun social gatherings here, as well as gotten \n plenty of work done thanks to neighborhood WiFi.\n </p>\n "}],"item":[{"value":"Crepes on Cole","type":["h-card"],"properties":{"name":["Crepes on Cole"],"org":["Crepes on Cole"],"adr":[{"value":"San Francisco","type":["h-adr"],"properties":{"locality":["San Francisco"],"name":["San Francisco"]}}]}}],"category":["crepe"],"url":["http://example.com/crepe"]}}],"rels":{"license":["http://en.wikipedia.org/wiki/Wikipedia:Text_of_Creative_Commons_Attribution-ShareAlike_3.0_Unported_License"]},"rel-urls":{"http://en.wikipedia.org/wiki/Wikipedia:Text_of_Creative_Commons_Attribution-ShareAlike_3.0_Unported_License":{"text":"Creative Commons Attribution-ShareAlike License","rels":["license"]}}};
+
+ it('vcard', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-rel-duplicate-rels.js b/toolkit/components/microformats/test/standards-tests/mf-v2-rel-duplicate-rels.js
new file mode 100644
index 000000000..d65dfdf8b
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-rel-duplicate-rels.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/rel/duplicate-rels
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('rel', function() {
+ var htmlFragment = "<a href=\"http://ma.tt/2015/05/beethoven-mozart-bach/\" \n title=\"Permalink to Beethoven, Mozart, Bach\" rel=\"bookmark\">\n<time class=\"entry-date\" datetime=\"2015-05-31T22:42:00+00:00\">May 31, 2015</time></a></span>\n<a href=\"http://ma.tt/category/asides/\" rel=\"category tag\">Asides</a>\n<span class=\"author vcard\">\n<a class=\"url fn n\" href=\"http://ma.tt/author/saxmatt/\" \n title=\"View all posts by Matt\" rel=\"author\">Matt</a></span>\n<span class=\"date\"><a href=\"http://ma.tt/2015/06/jefferson-on-idleness/\" title=\"Permalink to Jefferson on Idleness\" rel=\"bookmark\"><time class=\"entry-date\" datetime=\"2015-06-02T21:26:00+00:00\">June 2, 2015</time></a></span>\n<span class=\"categories-links\"><a href=\"http://ma.tt/category/asides/\" rel=\"category tag\">Asides</a></span>\n<span class=\"author vcard\"><a class=\"url fn n\" href=\"http://ma.tt/author/saxmatt/\" title=\"View all posts by Matt\" rel=\"author\">Matt</a></span>\n";
+ var expected = {"rels":{"bookmark":["http://ma.tt/2015/05/beethoven-mozart-bach/","http://ma.tt/2015/06/jefferson-on-idleness/"],"category":["http://ma.tt/category/asides/"],"tag":["http://ma.tt/category/asides/"],"author":["http://ma.tt/author/saxmatt/"]},"items":[{"type":["h-card"],"properties":{"url":["http://ma.tt/author/saxmatt/"],"name":["Matt"]}},{"type":["h-card"],"properties":{"url":["http://ma.tt/author/saxmatt/"],"name":["Matt"]}}],"rel-urls":{"http://ma.tt/category/asides/":{"rels":["category","tag"],"text":"Asides"},"http://ma.tt/author/saxmatt/":{"rels":["author"],"text":"Matt","title":"View all posts by Matt"},"http://ma.tt/2015/05/beethoven-mozart-bach/":{"rels":["bookmark"],"text":"May 31, 2015","title":"Permalink to Beethoven, Mozart, Bach"},"http://ma.tt/2015/06/jefferson-on-idleness/":{"rels":["bookmark"],"text":"June 2, 2015","title":"Permalink to Jefferson on Idleness"}}};
+
+ it('duplicate-rels', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-rel-license.js b/toolkit/components/microformats/test/standards-tests/mf-v2-rel-license.js
new file mode 100644
index 000000000..d5606f5a3
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-rel-license.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/rel/license
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('rel', function() {
+ var htmlFragment = "<a rel=\"license\" href=\"http://creativecommons.org/licenses/by/2.5/\">cc by 2.5</a>";
+ var expected = {"items":[],"rels":{"license":["http://creativecommons.org/licenses/by/2.5/"]},"rel-urls":{"http://creativecommons.org/licenses/by/2.5/":{"text":"cc by 2.5","rels":["license"]}}};
+
+ it('license', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-rel-nofollow.js b/toolkit/components/microformats/test/standards-tests/mf-v2-rel-nofollow.js
new file mode 100644
index 000000000..4332d3572
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-rel-nofollow.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/rel/nofollow
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('rel', function() {
+ var htmlFragment = "<a rel=\"nofollow\" href=\"http://microformats.org/wiki/microformats:copyrights\">Copyrights</a>";
+ var expected = {"items":[],"rels":{"nofollow":["http://microformats.org/wiki/microformats:copyrights"]},"rel-urls":{"http://microformats.org/wiki/microformats:copyrights":{"text":"Copyrights","rels":["nofollow"]}}};
+
+ it('nofollow', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-rel-rel-urls.js b/toolkit/components/microformats/test/standards-tests/mf-v2-rel-rel-urls.js
new file mode 100644
index 000000000..685532f44
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-rel-rel-urls.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/rel/rel-urls
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('rel', function() {
+ var htmlFragment = "<a rel=\"author\" href=\"http://example.com/a\">author a</a>\n<a rel=\"author\" href=\"http://example.com/b\">author b</a>\n<a rel=\"in-reply-to\" href=\"http://example.com/1\">post 1</a>\n<a rel=\"in-reply-to\" href=\"http://example.com/2\">post 2</a>\n<a rel=\"alternate home\"\n href=\"http://example.com/fr\"\n media=\"handheld\"\n hreflang=\"fr\">French mobile homepage</a>";
+ var expected = {"items":[],"rels":{"author":["http://example.com/a","http://example.com/b"],"in-reply-to":["http://example.com/1","http://example.com/2"],"home":["http://example.com/fr"],"alternate":["http://example.com/fr"]},"rel-urls":{"http://example.com/a":{"rels":["author"],"text":"author a"},"http://example.com/b":{"rels":["author"],"text":"author b"},"http://example.com/1":{"rels":["in-reply-to"],"text":"post 1"},"http://example.com/2":{"rels":["in-reply-to"],"text":"post 2"},"http://example.com/fr":{"rels":["alternate","home"],"media":"handheld","hreflang":"fr","text":"French mobile homepage"}}};
+
+ it('rel-urls', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-rel-varying-text-duplicate-rels.js b/toolkit/components/microformats/test/standards-tests/mf-v2-rel-varying-text-duplicate-rels.js
new file mode 100644
index 000000000..3b1b72f44
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-rel-varying-text-duplicate-rels.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/rel/varying-text-duplicate-rels
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('rel', function() {
+ var htmlFragment = "This is a contrived example - not found links like this in the wild:\n<a href=\"http://ma.tt/category/asides/\" rel=\"category tag\">Asides</a>\n<a href=\"http://ma.tt/category/asides/\" rel=\"category tag\">B-sides</a>\n<a href=\"http://ma.tt/category/asides/\" rel=\"category tag\">seasides</a>";
+ var expected = {"rels":{"category":["http://ma.tt/category/asides/"],"tag":["http://ma.tt/category/asides/"]},"items":[],"rel-urls":{"http://ma.tt/category/asides/":{"rels":["category","tag"],"text":"Asides"}}};
+
+ it('varying-text-duplicate-rels', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-rel-xfn-all.js b/toolkit/components/microformats/test/standards-tests/mf-v2-rel-xfn-all.js
new file mode 100644
index 000000000..3850ad564
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-rel-xfn-all.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/rel/xfn-all
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('rel', function() {
+ var htmlFragment = "<ul>\n <li><a rel=\"friend\" href=\"http://example.com/profile/jane\">jane</a></li>\n <li><a rel=\"acquaintance\" href=\"http://example.com/profile/jeo\">jeo</a></li>\n <li><a rel=\"contact\" href=\"http://example.com/profile/lily\">lily</a></li>\n <li><a rel=\"met\" href=\"http://example.com/profile/oliver\">oliver</a></li>\n <li><a rel=\"co-worker\" href=\"http://example.com/profile/emily\">emily</a></li>\n <li><a rel=\"colleague\" href=\"http://example.com/profile/jack\">jack</a></li>\n <li><a rel=\"neighbor\" href=\"http://example.com/profile/isabella\">isabella</a></li>\n <li><a rel=\"child\" href=\"http://example.com/profile/harry\">harry</a></li>\n <li><a rel=\"parent\" href=\"http://example.com/profile/sophia\">sophia</a></li>\n <li><a rel=\"sibling\" href=\"http://example.com/profile/charlie\">charlie</a></li>\n <li><a rel=\"spouse\" href=\"http://example.com/profile/olivia\">olivia</a></li>\n <li><a rel=\"kin\" href=\"http://example.com/profile/james\">james</a></li>\n <li><a rel=\"muse\" href=\"http://example.com/profile/ava\">ava</a></li>\n <li><a rel=\"crush\" href=\"http://example.com/profile/joshua\">joshua</a></li>\n <li><a rel=\"date\" href=\"http://example.com/profile/chloe\">chloe</a></li>\n <li><a rel=\"sweetheart\" href=\"http://example.com/profile/alfie\">alfie</a></li>\n <li><a rel=\"me\" href=\"http://example.com/profile/isla\">isla</a></li>\n</ul>";
+ var expected = {"items":[],"rels":{"friend":["http://example.com/profile/jane"],"acquaintance":["http://example.com/profile/jeo"],"contact":["http://example.com/profile/lily"],"met":["http://example.com/profile/oliver"],"co-worker":["http://example.com/profile/emily"],"colleague":["http://example.com/profile/jack"],"neighbor":["http://example.com/profile/isabella"],"child":["http://example.com/profile/harry"],"parent":["http://example.com/profile/sophia"],"sibling":["http://example.com/profile/charlie"],"spouse":["http://example.com/profile/olivia"],"kin":["http://example.com/profile/james"],"muse":["http://example.com/profile/ava"],"crush":["http://example.com/profile/joshua"],"date":["http://example.com/profile/chloe"],"sweetheart":["http://example.com/profile/alfie"],"me":["http://example.com/profile/isla"]},"rel-urls":{"http://example.com/profile/jane":{"text":"jane","rels":["friend"]},"http://example.com/profile/jeo":{"text":"jeo","rels":["acquaintance"]},"http://example.com/profile/lily":{"text":"lily","rels":["contact"]},"http://example.com/profile/oliver":{"text":"oliver","rels":["met"]},"http://example.com/profile/emily":{"text":"emily","rels":["co-worker"]},"http://example.com/profile/jack":{"text":"jack","rels":["colleague"]},"http://example.com/profile/isabella":{"text":"isabella","rels":["neighbor"]},"http://example.com/profile/harry":{"text":"harry","rels":["child"]},"http://example.com/profile/sophia":{"text":"sophia","rels":["parent"]},"http://example.com/profile/charlie":{"text":"charlie","rels":["sibling"]},"http://example.com/profile/olivia":{"text":"olivia","rels":["spouse"]},"http://example.com/profile/james":{"text":"james","rels":["kin"]},"http://example.com/profile/ava":{"text":"ava","rels":["muse"]},"http://example.com/profile/joshua":{"text":"joshua","rels":["crush"]},"http://example.com/profile/chloe":{"text":"chloe","rels":["date"]},"http://example.com/profile/alfie":{"text":"alfie","rels":["sweetheart"]},"http://example.com/profile/isla":{"text":"isla","rels":["me"]}}};
+
+ it('xfn-all', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});
diff --git a/toolkit/components/microformats/test/standards-tests/mf-v2-rel-xfn-elsewhere.js b/toolkit/components/microformats/test/standards-tests/mf-v2-rel-xfn-elsewhere.js
new file mode 100644
index 000000000..d982af5cc
--- /dev/null
+++ b/toolkit/components/microformats/test/standards-tests/mf-v2-rel-xfn-elsewhere.js
@@ -0,0 +1,27 @@
+/*
+Microformats Test Suite - Downloaded from github repo: microformats/tests version v0.1.24
+Mocha integration test from: microformats-v2/rel/xfn-elsewhere
+The test was built on Fri Sep 25 2015 13:26:26 GMT+0100 (BST)
+*/
+
+assert = chai.assert;
+
+
+describe('rel', function() {
+ var htmlFragment = "<ul>\n <li><a rel=\"me\" href=\"http://twitter.com/glennjones\">twitter</a></li>\n <li><a rel=\"me\" href=\"http://delicious.com/glennjonesnet/\">delicious</a></li>\n <li><a rel=\"me\" href=\"https://plus.google.com/u/0/105161464208920272734/about\">google+</a></li>\n <li><a rel=\"me\" href=\"http://lanyrd.com/people/glennjones/\">lanyrd</a></li>\n <li><a rel=\"me\" href=\"http://github.com/glennjones\">github</a></li>\n <li><a rel=\"me\" href=\"http://www.flickr.com/photos/glennjonesnet/\">flickr</a></li>\n <li><a rel=\"me\" href=\"http://www.linkedin.com/in/glennjones\">linkedin</a></li>\n <li><a rel=\"me\" href=\"http://www.slideshare.net/glennjones/presentations\">slideshare</a></li>\n</ul>";
+ var expected = {"items":[],"rels":{"me":["http://twitter.com/glennjones","http://delicious.com/glennjonesnet/","https://plus.google.com/u/0/105161464208920272734/about","http://lanyrd.com/people/glennjones/","http://github.com/glennjones","http://www.flickr.com/photos/glennjonesnet/","http://www.linkedin.com/in/glennjones","http://www.slideshare.net/glennjones/presentations"]},"rel-urls":{"http://twitter.com/glennjones":{"text":"twitter","rels":["me"]},"http://delicious.com/glennjonesnet/":{"text":"delicious","rels":["me"]},"https://plus.google.com/u/0/105161464208920272734/about":{"text":"google+","rels":["me"]},"http://lanyrd.com/people/glennjones/":{"text":"lanyrd","rels":["me"]},"http://github.com/glennjones":{"text":"github","rels":["me"]},"http://www.flickr.com/photos/glennjonesnet/":{"text":"flickr","rels":["me"]},"http://www.linkedin.com/in/glennjones":{"text":"linkedin","rels":["me"]},"http://www.slideshare.net/glennjones/presentations":{"text":"slideshare","rels":["me"]}}};
+
+ it('xfn-elsewhere', function(){
+ var doc, dom, node, options, parser, found;
+ dom = new DOMParser();
+ doc = dom.parseFromString( htmlFragment, 'text/html' );
+ options ={
+ 'document': doc,
+ 'node': doc,
+ 'baseUrl': 'http://example.com',
+ 'dateFormat': 'html5'
+ };
+ found = Microformats.get( options );
+ assert.deepEqual(found, expected);
+ });
+});