How do I test lines that are skipped in catch block with Jest unit test?

前端 未结 0 1925
执笔经年
执笔经年 2021-01-20 15:56

Okay maybe not a best title, but I have the follow block of code:

async function createUser((req,res,next) => {
  try {
    const user = new User({ userInf         


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题