import React from 'react';
import { render } from '@testing-library/react';
import Tooltip from './Tooltip';
it('renders Tooltip unchanged', () => {
const { container } = render(
Hover me
);
expect(container).toMatchSnapshot();
});
it('renders Tooltip with jsx content unchanged', () => {
const { container } = render(
Here we have some JSX, useful for
links
, for example.
}
>
Hover me
);
expect(container).toMatchSnapshot();
});
it('renders Tooltip disabled unchanged', () => {
const { container } = render(
Hover me
);
expect(container).toMatchSnapshot();
});
it('renders Tooltip visible unchanged', () => {
const { container } = render(
Hover me
);
expect(container).toMatchSnapshot();
});
it('renders Tooltip aligned left unchanged', () => {
const { container } = render(
Hover me
);
expect(container).toMatchSnapshot();
});
it('renders Tooltip aligned top left unchanged', () => {
const { container } = render(
Hover me
);
expect(container).toMatchSnapshot();
});
it('renders Tooltip aligned right unchanged', () => {
const { container } = render(
Hover me
);
expect(container).toMatchSnapshot();
});
it('renders Tooltip aligned top right unchanged', () => {
const { container } = render(
Hover me
);
expect(container).toMatchSnapshot();
});