splitDiff.spec.jsx 649 B

12345678910111213141516171819202122232425
  1. import {mountWithTheme} from 'sentry-test/enzyme';
  2. import SplitDiff from 'app/components/splitDiff';
  3. describe('SplitDiff', function () {
  4. beforeEach(function () {});
  5. afterEach(function () {});
  6. it('renders', function () {
  7. const wrapper = mountWithTheme(<SplitDiff base="restaurant" target="aura" />);
  8. expect(wrapper).toSnapshot();
  9. });
  10. it('renders with newlines', function () {
  11. const base = `this is my restaurant
  12. and restaurant
  13. common`;
  14. const target = `aura
  15. and your aura
  16. common`;
  17. const wrapper = mountWithTheme(<SplitDiff base={base} target={target} />);
  18. expect(wrapper).toSnapshot();
  19. });
  20. });