Skip to content

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
alimpens committed May 24, 2024
1 parent c45998e commit cf3c294
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions packages/react/src/FieldSet/FieldSet.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,23 +18,23 @@ describe('FieldSet', () => {

const component = screen.getByRole('group', { name: 'Test' })

expect(component).toHaveClass('ams-fieldSet')
expect(component).toHaveClass('ams-field-set')
})

it('renders an additional class name', () => {
render(<FieldSet legend="Test" className="extra" />)

const component = screen.getByRole('group', { name: 'Test' })

expect(component).toHaveClass('ams-fieldSet extra')
expect(component).toHaveClass('ams-field-set extra')
})

it('renders the correct legend class name', () => {
const { container } = render(<FieldSet legend="Test" />)

const component = container.querySelector('legend')

expect(component).toHaveClass('ams-fieldSet__legend')
expect(component).toHaveClass('ams-field-set__legend')
})

it('supports ForwardRef in React', () => {
Expand Down
6 changes: 3 additions & 3 deletions packages/react/src/Fieldset/Fieldset.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,23 +18,23 @@ describe('FieldSet', () => {

const component = screen.getByRole('group', { name: 'Test' })

expect(component).toHaveClass('ams-fieldSet')
expect(component).toHaveClass('ams-field-set')
})

it('renders an additional class name', () => {
render(<FieldSet legend="Test" className="extra" />)

const component = screen.getByRole('group', { name: 'Test' })

expect(component).toHaveClass('ams-fieldSet extra')
expect(component).toHaveClass('ams-field-set extra')
})

it('renders the correct legend class name', () => {
const { container } = render(<FieldSet legend="Test" />)

const component = container.querySelector('legend')

expect(component).toHaveClass('ams-fieldSet__legend')
expect(component).toHaveClass('ams-field-set__legend')
})

it('supports ForwardRef in React', () => {
Expand Down

0 comments on commit cf3c294

Please sign in to comment.