microformats / tests

Microformats test suite
http://microformats.org/wiki/microformats2
Creative Commons Zero v1.0 Universal
64 stars 20 forks source link

Fix tests that parse "value" for nested microformat when not a property #58

Closed gRegorLove closed 6 years ago

gRegorLove commented 7 years ago

value should only be parsed for nested microformats when they also have a property class. Multiple tests have a value in the expected output when they shouldn't.

Please comment with others as they're discovered.

mf2py parses correctly:

{
    "rels": {}, 
    "items": [
        {
            "type": [
                "h-card"
            ], 
            "properties": {
                "url": [
                    "http://blog.lizardwrangler.com/"
                ], 
                "name": [
                    "Mitchell Baker"
                ]
            }, 
            "children": [
                {
                    "type": [
                        "h-org", 
                        "h-card"
                    ], 
                    "properties": {
                        "url": [
                            "http://mozilla.org/"
                        ], 
                        "name": [
                            "Mozilla Foundation"
                        ]
                    }
                }
            ]
        }
    ], 
    "rel-urls": {}
}

Reference: http://microformats.org/wiki/microformats2-parsing##if+that+child+element+itself+has+a+microformat php-mf2 issue: https://github.com/indieweb/php-mf2/issues/98 mf2py resolved issue: https://github.com/indieweb/php-mf2/issues/99

gRegorLove commented 7 years ago

Similar issue previously fixed: https://github.com/microformats/tests/pull/53

dissolve commented 7 years ago

I think these are all fixed now https://github.com/microformats/tests/commit/59cabf19228472deb4be46ddd9432a64185b7b01#diff-f21c1ccd7a418443c9debd5c772701a7

gRegorLove commented 6 years ago

Resolved per above.