Skip to content

Commit ebdb777

Browse files
committed
Tests
1 parent f7ec387 commit ebdb777

File tree

3 files changed

+42
-0
lines changed

3 files changed

+42
-0
lines changed

Tests/MarkdownUITests/MarkdownTests.swift

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -300,5 +300,47 @@
300300

301301
assertSnapshot(of: view, as: .image(layout: layout))
302302
}
303+
304+
func testSoftBreakModeLineSpace() {
305+
let view = Markdown {
306+
#"""
307+
# This is a heading
308+
309+
Item 1
310+
Item 2
311+
Item 3
312+
Item 4
313+
314+
I would **very much** like to write
315+
A long paragraph that spans _multiple lines_
316+
But should ~~render differently~~ based on
317+
soft break mode
318+
"""#
319+
}
320+
.markdownSoftBreakMode(.space)
321+
322+
assertSnapshot(of: view, as: .image(layout: layout))
323+
}
324+
325+
func testSoftBreakModeLineBreak() {
326+
let view = Markdown {
327+
#"""
328+
# This is a heading
329+
330+
Item 1
331+
Item 2
332+
Item 3
333+
Item 4
334+
335+
I would **very much** like to write
336+
A long paragraph that spans _multiple lines_
337+
But should ~~render differently~~ based on
338+
soft break mode
339+
"""#
340+
}
341+
.markdownSoftBreakMode(.lineBreak)
342+
343+
assertSnapshot(of: view, as: .image(layout: layout))
344+
}
303345
}
304346
#endif
60.4 KB
Loading
55.9 KB
Loading

0 commit comments

Comments
 (0)