diff --git a/test/lib/construct.test.ts b/test/lib/construct.test.ts index 09ee325..9904619 100644 --- a/test/lib/construct.test.ts +++ b/test/lib/construct.test.ts @@ -261,14 +261,14 @@ describe('lib/construct', () => { it('should dedupe class names where required', () => { const parameters: ConstructOptions = { - attrs: { isPrimary: true }, + attrs: { className: 'heading', isPrimary: true }, classNames: 'heading', styles: styles, target: 'h1', }; render(createElement(construct(parameters), { isPrimary: true })); - expect(screen.getByRole('heading')).toHaveClass('heading heading--primary'); + expect(screen.getByRole('heading').className).toMatch('heading heading--primary'); }); it('should convert `style` props to a dynamically rendered class name', () => {