-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: 초대하기 모달 Modal Context 적용 #272
- Loading branch information
Showing
2 changed files
with
27 additions
and
3 deletions.
There are no files selected for viewing
21 changes: 21 additions & 0 deletions
21
frontend/src/components/ReadyMembersContainer/ReadyMembersContainer.test.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
import { screen, waitFor } from '@testing-library/react'; | ||
import { userEvent } from '@testing-library/user-event'; | ||
|
||
import ReadyMembersContainer from './ReadyMembersContainer'; | ||
|
||
import { customRender } from '@/utils/test-utils'; | ||
|
||
describe('ReadyMembersContainer 테스트', () => { | ||
it('초대하기 버튼을 클릭했을 때, 초대 모달이 뜬다.', async () => { | ||
const user = userEvent.setup(); | ||
customRender(<ReadyMembersContainer />); | ||
|
||
const inviteButton = await screen.findByText('초대하기'); | ||
await user.click(inviteButton); | ||
|
||
await waitFor(() => { | ||
const copyText = screen.getByText('초대 링크 복사'); | ||
expect(copyText).toBeInTheDocument(); | ||
}); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters