How to test a component for desktop app?

I've made some changes to a component, and want to test if it works well. However, when I run yarn test <filename>, it is saying:

No such module was linked: electron_common_features

  at Object.getElectronBinding (node_modules/@electron/remote/dist/src/common/get-electron-binding.js:6:24)
  at Object.<anonymous> (node_modules/@electron/remote/dist/src/common/module-names.js:44:41)
  at Object.<anonymous> (node_modules/@electron/remote/dist/src/renderer/remote.js:7:24)

How do I fix this error?