Skip to content

Commit

Permalink
Fix the last broken test of MicrodownParserTest
Browse files Browse the repository at this point in the history
  • Loading branch information
quentin.moutte.etu committed Aug 21, 2024
1 parent 14d2c52 commit d199cee
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions src/Microdown-Tests/MicrodownParserTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -103,8 +103,9 @@ MicrodownParserTest >> testAnnotatedBlock [
MicrodownParserTest >> testAnnotatedBlockOnMultipleLinesParserLogic [

| source root annotated line |
source := (AnnotatedParagraphMarkup , 'important this is an
important point because...!') readStream.
source := (AnnotatedParagraphMarkup , 'important]
> this is an
> important point because...!') readStream.

"first the root block"
root := parser parse: ''.
Expand All @@ -116,9 +117,15 @@ important point because...!') readStream.
self assert: annotated parent equals: root.

self assert: annotated label equals: 'important'.
self assert: (annotated instVarNamed: 'body') equals: 'this is an'.

"third the second line"
line := source nextLine.
self assert: (annotated canConsumeLine: line).
annotated := parser handleLine: line.
self assert: parser current equals: annotated.
self assert: (annotated instVarNamed: 'body') equals: 'this is an'.

"fourth the third line"
line := source nextLine.
self assert: (annotated canConsumeLine: line).
annotated := parser handleLine: line.
Expand Down

0 comments on commit d199cee

Please sign in to comment.