From f4a5bbfb37813448c591e534e6dcaee49931ed44 Mon Sep 17 00:00:00 2001 From: Arman Date: Wed, 8 Feb 2023 10:04:21 +0100 Subject: [PATCH] test: update tests --- tests/unit/components/dropTabsItem.test.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/tests/unit/components/dropTabsItem.test.ts b/tests/unit/components/dropTabsItem.test.ts index 65de83fa4..ddd8130da 100644 --- a/tests/unit/components/dropTabsItem.test.ts +++ b/tests/unit/components/dropTabsItem.test.ts @@ -9,8 +9,14 @@ test('shows button', () => { expect(getByRole('button')).toBeInTheDocument(); }); +test('shows link', () => { + render(SecondaryTabsItem, { href: 'https://www.appwrite.io' }); + const href = document.querySelector('a'); + expect(href).toBeInTheDocument(); +}); + test('shows button - disabled', () => { - const { getByRole } = render(SecondaryTabsItem, { disabled: true }); + const { getByRole } = render(SecondaryTabsItem, { href: null, disabled: true }); expect(getByRole('button')).toBeDisabled(); });