This commit is contained in:
@@ -11,15 +11,13 @@ describe ('common typography and form components', () => {
|
||||
it ('renders Form children inside the standard container', () => {
|
||||
render (<Form><span>Content</span></Form>)
|
||||
|
||||
expect (screen.getByText ('Content').parentElement).toHaveClass ('max-w-xl')
|
||||
expect (screen.getByText ('Content')).toBeInTheDocument ()
|
||||
})
|
||||
|
||||
it ('renders SectionTitle as an h2 and merges custom classes', () => {
|
||||
render (<SectionTitle className="custom">Section</SectionTitle>)
|
||||
it ('renders SectionTitle as an h2', () => {
|
||||
render (<SectionTitle>Section</SectionTitle>)
|
||||
|
||||
const heading = screen.getByRole ('heading', { level: 2, name: 'Section' })
|
||||
expect (heading).toHaveClass ('text-xl')
|
||||
expect (heading).toHaveClass ('custom')
|
||||
expect (screen.getByRole ('heading', { level: 2, name: 'Section' })).toBeInTheDocument ()
|
||||
})
|
||||
|
||||
it ('renders SubsectionTitle as an h3', () => {
|
||||
|
||||
Reference in New Issue
Block a user