setTimeout()
和done()
函数:it("Spec with requestAnimationFrame", (done) => {
window.requestAnimationFrame(() => {
// Do something testable here
});
setTimeout(function() {
// Verify testable values here
done();
}, 200);
});
describe
和it
块的标签写成什么? - Jamie Mason