h-review-aggregate parsing tests

This page was design to test the parsing of h-review-aggregate. These tests are part of the micorformats 2 test suite.

Minimum properties (h-review-aggregate parsing test)

Mediterranean Wraps

Customers flock to this small restaurant for their tasty falafel and shawerma wraps and welcoming staff. 4.5 out of 5

The expected JSON output:


{
    "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 tasty falafel and shawerma wraps and welcoming staff."],
            "rating": ["4.5"],
            "name": ["Mediterranean Wraps Customers flock to this small restaurant for their tasty falafel and shawerma wraps and welcoming staff. 4.5 out of 5"]
        }
    }]
}

Broken into properties (h-review-aggregate parsing test)

Mediterranean Wraps

433 S California Ave, Palo Alto, CA - (650) 321-8189

Customers flock to this small restaurant for their tasty falafel and shawerma wraps and welcoming staff. 9.2 out of 10 based on 17 reviews

The expected JSON output:


{
    "items": [{
        "type": ["h-review-aggregate"],
        "properties": {
            "item": [{
                "value": "Mediterranean Wraps 433 S California Ave, Palo Alto, CA - (650) 321-8189",
                "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 tasty falafel and shawerma wraps and welcoming staff."],
            "rating": ["9.2"],
            "average": ["9.2"],
            "best": ["10"],
            "count": ["17"],
            "name": ["Mediterranean Wraps 433 S California Ave, Palo Alto, CA - (650) 321-8189 Customers flock to this small restaurant for their tasty falafel and shawerma wraps and welcoming staff. 9.2 out of 10 based on 17 reviews"]
        }
    }]
}

With p-item as a h-event (hreview-aggregate parsing test)

Fullfrontal

A one day JavaScript Conference held in Brighton

9.9 out of 10 based on 62 reviews

The expected JSON output:


{
    "items": [{
        "type": ["h-review-aggregate"],
        "properties": {
            "item": [{
                "value": "Fullfrontal A one day JavaScript Conference held in Brighton 9th November 2012",
                "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 A one day JavaScript Conference held in Brighton 9th November 2012 9.9 out of 10 based on 62 reviews"]
        }
    }]
}

Change log:

Contributors :