Jest error with conditions on props.

I am trying to test if layout.js if it calles a fetch service, this works. But in layout.js, page.js is rendered and my fetched data is added as a prop. I mock the service an data and I return []. But in page.js I only show the data when it is not empty but I keep getting an error when using this condition. I've already tried with returning just random types and random conditions like strings but it doesn't help. I am using jest for the testing in Next.js.
No description
No description
0 Replies
No replies yetBe the first to reply to this messageJoin
Want results from more Discord servers?
Add your server