unexpected-promise:意外断言库的插件添加了Promise支持

时间:2021-05-26 06:02:08
【文件属性】:
文件名称:unexpected-promise:意外断言库的插件添加了Promise支持
文件大小:884KB
文件格式:ZIP
更新时间:2021-05-26 06:02:08
JavaScript 意料之外的承诺 意外断言库的插件添加了Promise支持。 需要非预期的7或更高。 注意:该模块应该被认为是不受欢迎的,因为它具有8.5.0+内置的功能! var expect = require ( 'unexpected' ) . installPlugin ( require ( 'unexpected-promise' ) ) ; it ( 'should DTRT' , function ( ) { return expect ( myPromise , 'to be resolved with' , 'foobar' ) ; } ) ; it ( 'should fail' , function ( ) { return expect ( myPromise , 'to be rejected with' , new Error ( 'argh' ) ) ;
【文件预览】:
unexpected-promise-master
----.jshintrc(5KB)
----.jshintignore(22B)
----logoImage.jpg(878KB)
----lib()
--------unexpectedPromise.js(3KB)
----.travis.yml(137B)
----LICENSE(1KB)
----test()
--------unexpectedPromise.js(13KB)
--------mocha.opts(22B)
----README.md(2KB)
----.gitignore(26B)
----package.json(1KB)

网友评论