Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TW is not defined #55

Open
WebTerminator opened this issue Aug 20, 2020 · 1 comment
Open

TW is not defined #55

WebTerminator opened this issue Aug 20, 2020 · 1 comment

Comments

@WebTerminator
Copy link

I have a Next.js app setup with TS, Tailwind and Styled-Components. Storybook and the application work fine in displaying my components however my tests are failing:

my component:
export const HamburgerIconWrapper = tw.div flex flex-1 justify-start sm:hidden

my test:

test("renders HamburgerIconWrapper snapshot", async () => {
    let renderedComp
    await act(async () => {
        renderedComp = render(<HamburgerIconWrapper />)
    })
    expect(renderedComp.asFragment()).toMatchSnapshot()
})

Result:
Screen Shot 2020-08-20 at 14 32 28

@tcarac
Copy link

tcarac commented Dec 10, 2020

Same scenario

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants