dylanblokhuis/svelte-feather-icons

Jest: `TypeError: Cannot read property '$$' of undefined`

Opened this issue · 0 comments

asode commented

After updating svelte-feather-icons to 3.5.1, I'm getting the following error when running jest:

● <PriceBox /> › Should render all props without sale

    TypeError: Cannot read property '$$' of undefined

      at B (node_modules/svelte-feather-icons/index.js:1:1820)
      at new Object.<anonymous>.e.CheckCircleIcon (node_modules/svelte-feather-icons/index.js:1:301082)
      at create_each_block (src/components/priceBox/PriceBox.svelte:138:20)
      at create_fragment (src/components/priceBox/PriceBox.svelte:218:20)
      at init (node_modules/svelte/internal/index.js:1880:37)
      at new PriceBox (src/components/priceBox/PriceBox.svelte:456:3)
      at render (node_modules/@testing-library/svelte/dist/pure.js:81:21)
      at Object.<anonymous> (src/components/priceBox/PriceBox.test.ts:22:11)

Test Suites: 1 failed, 1 total
Tests:       1 failed, 1 total
Snapshots:   0 total
Time:        2.395 s, estimated 3 s

Downgrading to 3.5.0 fixes the issue.