Skip to content

Commit

Permalink
test: add component tests
Browse files Browse the repository at this point in the history
  • Loading branch information
adamdehaven committed Jan 4, 2024
1 parent 6f91fa8 commit a420aa5
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/components/MarkdownUi.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -391,6 +391,7 @@ describe('<MarkdownUi />', () => {
expect(wrapper.findTestId('markdown-content').classes('html-preview')).toBe(false)
// Ensure the HTML preview does not exist
expect(wrapper.find('pre > code.language-html').exists()).toBe(false)
expect(wrapper.findTestId('copy-code-button').exists()).toBe(false)

// Both panes should be visible
expect(wrapper.findTestId('markdown-editor-textarea').isVisible()).toBe(true)
Expand All @@ -412,6 +413,7 @@ describe('<MarkdownUi />', () => {
expect(wrapper.findTestId('markdown-content').classes('html-preview')).toBe(true)

expect(wrapper.find('pre > code.language-html').isVisible()).toBe(true)
expect(wrapper.findTestId('copy-code-button').isVisible()).toBe(true)
})
})
})

0 comments on commit a420aa5

Please sign in to comment.