Skip to content

Commit

Permalink
테스트들을 describe블럭으로 묶어라
Browse files Browse the repository at this point in the history
  • Loading branch information
yujonglee committed May 26, 2021
1 parent 803fe83 commit 72a27f6
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions src/presentational/Input.test.jsx
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
import { render } from '@testing-library/react';
import Input from './Input';

it('renders input control', () => {
const { getByPlaceholderText } = render(<Input />);
expect(getByPlaceholderText('할 일을 입력해 주세요')).toBeInTheDocument();
});
describe('Input', () => {
it('renders input control', () => {
const { getByPlaceholderText } = render(<Input />);
expect(getByPlaceholderText('할 일을 입력해 주세요')).toBeInTheDocument();
});

it('renders 추가 button', () => {
const { getByRole } = render(<Input />);
expect(getByRole('button', { name: '추가' })).toBeInTheDocument();
it('renders 추가 button', () => {
const { getByRole } = render(<Input />);
expect(getByRole('button', { name: '추가' })).toBeInTheDocument();
});
});

0 comments on commit 72a27f6

Please sign in to comment.