Skip to content

Commit

Permalink
Add tests.
Browse files Browse the repository at this point in the history
  • Loading branch information
jverkoey committed Aug 6, 2024
1 parent efccdbd commit b67d294
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
3 changes: 3 additions & 0 deletions Tests/SlipstreamTests/Sites/CatalogSiteTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,8 @@ private struct CatalogSite: View {
.textColor(.white)
.display(.hidden)

Divider()

Heading(level: 2, "Generic heading 2")
}
.background(.black)
Expand Down Expand Up @@ -107,6 +109,7 @@ struct CatalogSiteTests {
<h4 class="antialiased h-12 max-h-24 max-w-4 min-h-6 min-w-1 w-2">Heading 4</h4>
<h5 class="mx-auto">Heading 5</h5>
<h6 class="my-8 text-white hidden">Heading 6</h6>
<hr />
<h2>Generic heading 2</h2>
</div>
</div>
Expand Down
9 changes: 9 additions & 0 deletions Tests/SlipstreamTests/W3C/DividerTests.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import Testing

import Slipstream

struct DividerTests {
@Test func divider() throws {
try #expect(renderHTML(Divider()) == "<hr />")
}
}

0 comments on commit b67d294

Please sign in to comment.