-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
adding test case for sections closing too far #74
Conversation
f7d9fff
to
36b5bf5
Compare
@weaverryan I'm super late to the party but I think it is here: rst-parser/lib/Parser/DocumentParser.php Lines 486 to 496 in 55253fc
|
No we don't! 😛 |
788e424
to
890d05b
Compare
I fixed the test but broke other tests… whack-a-mole! |
890d05b
to
56916b8
Compare
@weaverryan @wouterj please review carefully, it looks super suspicious to me that I had to edit these extra test files. |
Just because there is a new chapter does not mean this is a new book.
56916b8
to
451cddf
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good!
Don't worry about having to edit other tests if you make a change: It's common in this package that the test files are copy-pasted from the output. E.g. the "titles" test is testing the h1
, h2
, etc. elements, the rest was just copy-pasted from the output and not looked at. In other words: tests may contain completely bad expectations
I noticed a minor issue with the
section
tags. Take the following situation:The
h2 Bazzles
should still be a child inside theh1 Foo
section. But the HTML markup closes and puts theh2
into a sibling div of theh1
.This includes a failing test case to show the behavior - but I'm not sure where this is controlled in the code.
Cheers!