score:14

Accepted answer

i always feel pretty silly when i spend a day researching my question prior to asking it, then i figure it out on my own 15 minutes later...

rather than deleting this i'm going to post the answer for anyone else that may have a similar issue. i realized that i'm using a wrapper for chart.js, react-chartjs-2 so i searched on their github and sure enough someone had already posted the exact answer to my question. https://github.com/jerairrest/react-chartjs-2/issues/155

adding the following mock to my setup-jest.js file resolved the console errors i was getting.

jest.mock('react-chartjs-2', () => ({
  bar: () => null
}));

Related Query

More Query from same tag