diff --git a/src/components/button/button.test.ts b/src/components/button/button.test.ts index 1846f542..e13732af 100644 --- a/src/components/button/button.test.ts +++ b/src/components/button/button.test.ts @@ -2,7 +2,18 @@ import { expect, fixture, html } from '@open-wc/testing'; import sinon from 'sinon'; import type SlButton from './button'; +const variants = ['default', 'primary', 'success', 'neutral', 'warning', 'danger']; + describe('', () => { + describe('accessibility tests', () => { + variants.forEach(variant => { + it(`should be accessible when variant is "${variant}"`, async () => { + const el = await fixture(html` Button Label `); + await expect(el).to.be.accessible(); + }); + }); + }); + describe('when provided no parameters', () => { it('passes accessibility test', async () => { const el = await fixture(html` Button Label `);