import * as React from 'react';
import render from '../../_utils/tests/render';
import Toast from '../Toast';
it('renders correctly for a basic Toast', () => {
const { container } = render(
Anim pariatur cliche reprehenderit, enim eiusmod high life accusamus terry richardson ad squid. Nihil anim
keffiyeh helvetica.
);
expect(container.firstChild).toMatchSnapshot();
});
['info', 'success', 'danger', 'warning'].forEach(type => {
it(`renders correctly for a toast of type ${type}`, () => {
const { container } = render(
Anim pariatur cliche reprehenderit, enim eiusmod high life accusamus terry richardson ad squid. Nihil anim
keffiyeh helvetica.
);
expect(container.firstChild).toMatchSnapshot();
});
});
it('renders correctly for a Toast with a title', () => {
const { container } = render(
Anim pariatur cliche reprehenderit, enim eiusmod high life accusamus terry richardson ad squid. Nihil anim
keffiyeh helvetica.
);
expect(container.firstChild).toMatchSnapshot();
});
it('renders correctly for a Toast with no close button', () => {
const { container } = render(
Anim pariatur cliche reprehenderit, enim eiusmod high life accusamus terry richardson ad squid. Nihil anim
keffiyeh helvetica.
);
expect(container.firstChild).toMatchSnapshot();
});
it('renders correctly for a Toast with a horizontal bar', () => {
const { container } = render(
Anim pariatur cliche reprehenderit, enim eiusmod high life accusamus terry richardson ad squid. Nihil anim
keffiyeh helvetica.
);
expect(container.firstChild).toMatchSnapshot();
});
['info', 'success', 'danger', 'warning'].forEach(type => {
it(`renders correctly for a tinted toast of type ${type}`, () => {
const { container } = render(
Anim pariatur cliche reprehenderit, enim eiusmod high life accusamus terry richardson ad squid. Nihil anim
keffiyeh helvetica.
);
expect(container.firstChild).toMatchSnapshot();
});
});
it('renders correctly for a Toast without a countdown bar', () => {
const { container } = render(
Anim pariatur cliche reprehenderit, enim eiusmod high life accusamus terry richardson ad squid. Nihil anim
keffiyeh helvetica.
);
expect(container.firstChild).toMatchSnapshot();
});