📜  mocha 应该抛出错误 - Javascript 代码示例

📅  最后修改于: 2022-03-11 15:02:29.105000             🧑  作者: Mango

代码示例2
expect(model.get.bind(model, 'z')).to.throw('Property does not exist in model schema.');
expect(model.get.bind(model, 'z')).to.throw(new Error('Property does not exist in model schema.'));