Created
July 8, 2021 13:13
-
-
Save lek890/3900bd8ba0a91cc5b57a672a73721fb7 to your computer and use it in GitHub Desktop.
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
import { render } from "@testing-library/react"; | |
import { UserProfile } from "./User"; | |
it("doesn't show the premium features", () => { | |
const { getByTestId } = render( | |
<UserProfile user={{ name: "Sheldon", isPremiumUser: false }} /> | |
); | |
expect(getByTestId("premiumFeatures")).toBeTruthy(); //throws | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment