import { beforeEach, describe, expect, it } from 'vitest' import { elementUpdated, fixture, html } from '@open-wc/testing-helpers' import './UsEmptyState' import type { UsEmptyState } from './UsEmptyState' describe('UsEmptyState', () => { let usEmptyState: UsEmptyState beforeEach(async () => { usEmptyState = await fixture(html``) }) it('should be defined', async () => { expect(usEmptyState).toBeDefined() expect(usEmptyState.tagName).toBe('US-EMPTY-STATE') }) it('should has correct initial properties', () => { expect(usEmptyState.title).toBe('') expect(usEmptyState.description).toBe('') expect(usEmptyState.dataTestId).toBe('empty_state') }) it('should be updated the props title & description', async () => { const testTitle = 'Some title' const testDescription = 'Some description' usEmptyState.title = testTitle usEmptyState.description = testDescription await elementUpdated(usEmptyState) expect(usEmptyState.title).toBe(testTitle) expect(usEmptyState.description).toBe(testDescription) }) })