Closed gRegorLove closed 8 months ago
Note there's still three "risky" tests that don't perform assertions. I didn't update those in this PR but can in a subsequent one.
LGTM, matches what I expect, but would like second review from someone deeper in PHP
Added an additional test that @sknebel provided:
<div class=" h-5 pt-2">
<div class="p-4 h-entry">
<a class="u-url" href="https://example.com/bar">bar </a>
</div>
<div class="p-4 h-entry">
<a class="u-url" href="https://example.com/foo">foo</a>
</div>
</div>
Parsed empty on http://php.microformats.io/?id=20231011231942570
The
nestedMfPropertyNamesFromClass
method was parsing property classes regardless if they were valid (e.g.p-4
). Updated the method to use existingmfNamesFromClass
method, which uses the correct regex to skip those classes.Also fixed a test for
nestedMfPropertyNamesFromClass
which asserted the response array was equal. The expected and actual response array had the same values, but in different order. The order is not important in that response, so I switched the assertion toassertEqualsCanonicalizing
.This also appeared to fix #246, so I added a test to confirm that.
Fixes #249 Fixes #246