Created
October 11, 2020 21:45
-
-
Save annacoding2020/389b4f819d3a9d0897df4556c2126294 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| import { render } from "@testing-library/react"; | |
| test("username exists", () => { | |
| const { queryByTestId } = render( | |
| <Avatar username="Timonweb" src="https://example.com/avatar.jpg" /> | |
| ); | |
| expect(queryByTestId(/username/i)).toBeTruthy(); | |
| }); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment