launch.json 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. {
  2. // 使用 IntelliSense 了解相关属性。
  3. // 悬停以查看现有属性的描述。
  4. // 欲了解更多信息,请访问: https://go.microsoft.com/fwlink/?linkid=830387
  5. "version": "0.2.0",
  6. "configurations": [
  7. {
  8. "name": "Debug UnitTest",
  9. "type": "node",
  10. "request": "launch",
  11. "runtimeArgs": [
  12. "--inspect-brk",
  13. "${workspaceRoot}/node_modules/.bin/jest",
  14. "${workspaceRoot}/packages/semi-ui/select/", // 需要调试哪个组件,替换文件夹路径即可
  15. "--runInBand",
  16. // "--coverage",
  17. "--silent" // ignore warning such as componentWillReceiveProps will be abondon...
  18. ],
  19. "env": {
  20. "NODE_ENV": "test",
  21. // "type": "story" // 调试snapshot快照的时候用这个
  22. "type": "unit" // 调试unitTest的时候用这个
  23. },
  24. "runtimeExecutable": "/Users/bytedance/.nvm/versions/node/v16.17.1/bin/node",
  25. "console": "integratedTerminal",
  26. "internalConsoleOptions": "neverOpen",
  27. "port": 9229
  28. },
  29. {
  30. "name": "Debug StorySnapShot",
  31. "type": "node",
  32. "request": "launch",
  33. "runtimeArgs": [
  34. "--inspect-brk",
  35. "${workspaceRoot}/node_modules/.bin/jest",
  36. "--runInBand",
  37. "--silent" // ignore warning such as componentWillReceiveProps will be abondon...
  38. ],
  39. "env": {
  40. "NODE_ENV": "test",
  41. "type": "story"
  42. },
  43. "console": "integratedTerminal",
  44. "internalConsoleOptions": "neverOpen",
  45. "port": 9229
  46. }
  47. ]
  48. }