import * as React from 'react';
import { render, cleanup } from '@testing-library/react';
import { axe, toHaveNoViolations } from 'jest-axe';
import { matchers } from 'jest-emotion';
import { MiniCart, CartLink, MiniCartLink } from './';
import { Cart } from '../cart';
expect.extend(matchers);
expect.extend(toHaveNoViolations);
describe('', () => {
it('should not have accessibility violations', async done => {
const { container, unmount } = render(
Login
register
);
const a11yResults = await axe(container);
expect(a11yResults).toHaveNoViolations();
cleanup();
unmount();
done();
});
});