Skip to content

Commit

Permalink
feat(Radio): add testid tests for Radio
Browse files Browse the repository at this point in the history
  • Loading branch information
chentsulin committed Feb 26, 2019
1 parent 080be48 commit 11de864
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions packages/tailor-ui/src/Radio/__tests__/index.spec.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,16 @@ describe('Radio', () => {

expect(onChange).toBeCalled();
});

it('should support data-testid', () => {
const { getByTestId } = render(
<Radio checked data-testid="my-radio">
Radio
</Radio>
);

expect(getByTestId('my-radio')).toHaveAttribute('checked');
});
});

describe('Radio.Group', () => {
Expand Down

0 comments on commit 11de864

Please sign in to comment.