import styled from 'styled-components';
const Button = styled.button`
background-color: #7D7D7D;
color: #FFF;
`;
export default Button;describe('Button Component', () => {
it('renders a button element', () => {
const wrapper = shallow(Button);
// this test is basically worthless
expect(wrapper).toBeA('button');
});
});import styled from 'styled-components';
const Button = styled.button`
background-color: #7D7D7D;
color: #FFF;
`;
export default Button;describe('Button Block', () => {
it('renders correctly', () => {
const tree = renderer
.create(<Button>Submit</Button>)
.toJSON();
expect(tree).toMatchSnapshot();
});
});