def METHOD_NAME(area_settings, location_factory):
    items = [location_factory()]
    points = {
        "type": "FeatureCollection",
        "features": [
            {
                "properties": {
                    "name": "",
                    "comments_count": "",
                    "url": pytest_regex("^/location/[0-9]*/$"),
                    "positive_rating_count": "",
                    "slug": "location",
                    "image": "",
                    "category_icon": "",
                    "negative_rating_count": "",
                    "vote_count": "",
                },
                "type": "Feature",
                "geometry": {"type": "Point", "coordinates": [1.0, 1.0]},
            }
        ],
    }
    template = "{% load maps_tags %}{% map_display_points items polygon %}"
    context = {"items": items, "polygon": area_settings.polygon}
    expected = (
        r"^<div"
        r' style="height: 300px"'
        r' data-map="display_points"'
        r' data-baseurl="{baseurl}"'
        r' data-usevectormap="0"'
        r' data-mapbox-token=""'
        r' data-omt-token=""'
        r' data-attribution="{attribution}"'
        r' data-points="(?P<points>{{.+}})"'
        r' data-polygon="(?P<polygon>{{.+}})"'
        ' data-hide-ratings="false"'
        ' data-hide-support="true"'
        ' data-hide-vote-count="true"'
        r"></div>$"
    ).format(
        baseurl=escape(settings.A4_MAP_BASEURL),
        attribution=escape(settings.A4_MAP_ATTRIBUTION),
    )
    match = re.match(expected, helpers.render_template(template, context))
    assert match
    _points = match.group("points")
    assert json.loads(unescape(_points)) == points
    _polygon = match.group("polygon")
    assert json.loads(unescape(_polygon)) == area_settings.polygon