File tree Expand file tree Collapse file tree 1 file changed +15
-0
lines changed Expand file tree Collapse file tree 1 file changed +15
-0
lines changed Original file line number Diff line number Diff line change @@ -283,6 +283,21 @@ final class MarkupTests: XCTestCase {
283283 ) !. debugDescription ( )
284284 )
285285 }
286+
287+ func testChildThroughIndicesWithMultipleParagraphs( ) {
288+ let source = """
289+ This is a markup __*document*__ with *some* **more** attributes.
290+
291+ This is the *second* paragraph.
292+ This is on a **new** line, but, continues on the same paragraph.
293+
294+ This is the *third* paragraph.
295+ This is on a **new** line, but, continues on the same paragraph.
296+ """
297+
298+ let document = Document ( parsing: source)
299+ XCTAssertNotNil ( document. child ( through: [ 2 , 5 ] ) as? Strong )
300+ }
286301
287302 func testChildAtPositionHasCorrectType( ) throws {
288303 let source = " This is a [*link*](github.com). And some **bold** and *italic* text. "
You can’t perform that action at this time.
0 commit comments