Skip to content

Commit

Permalink
test: added test for new body text logic
Browse files Browse the repository at this point in the history
Signed-off-by: al-rosenthal <[email protected]>
  • Loading branch information
al-rosenthal committed Nov 14, 2024
1 parent 648ba1a commit 7d65d97
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions packages/legacy/core/__tests__/components/BaseToast.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -51,4 +51,10 @@ describe('BaseToast Component', () => {

expect(tree).toMatchSnapshot()
})

test('Toast Renders without body text', () => {
const tree = render(<BaseToast title={'Hello World'} toastType={ToastType.Error} />)
const bodyText = tree.queryByTestId('ToastBody')
expect(bodyText).toBeNull()
})
})

0 comments on commit 7d65d97

Please sign in to comment.