chore: restructure project into yarn workspaces, remove next

This commit is contained in:
41666 2021-03-09 23:25:16 -05:00
parent 49e308507e
commit 8d06327c03
266 changed files with 16466 additions and 3350 deletions

View file

@ -0,0 +1,23 @@
import { Button } from '@roleypoly/design-system/atoms/button';
import { shallow } from 'enzyme';
import * as React from 'react';
import { ResetSubmit } from './ResetSubmit';
const onReset = jest.fn();
const onSubmit = jest.fn();
it('calls onReset when reset is clicked', () => {
const view = shallow(<ResetSubmit onSubmit={onSubmit} onReset={onReset} />);
view.find(Button).at(0).simulate('click');
expect(onReset).toBeCalled();
});
it('calls onSubmit when submit is clicked', () => {
const view = shallow(<ResetSubmit onSubmit={onSubmit} onReset={onReset} />);
view.find(Button).at(1).simulate('click');
expect(onSubmit).toBeCalled();
});