Jest: Test suite failed to run, Unexpected token =
问题 I am trying to test a React component with Jest/Enzyme. I expect the test to at least run, but it already fails when it is importing files and does not get to the test itself. So I am wondering what in the configuration I am missing? Error: __tests__/Favorite.test.js ● Test suite failed to run /src/components/favorite/Favorite.js: Unexpected token (13:13) 11 | } 12 | > 13 | isFavorite = (props) => { | ^ 14 | return localStorage.getItem(props.recipe.id) ? true : false 15 | } 16 | Test File: