DEV: migrate widgets tests to async/await

This commit is contained in:
Maja Komel
2018-07-24 17:49:42 +02:00
parent fe39cdc90a
commit 3a52c2fa64
6 changed files with 197 additions and 291 deletions

View File

@ -46,11 +46,9 @@ widgetTest("collapsed links", {
]
});
},
test(assert) {
async test(assert) {
assert.ok(this.$(".expand-links").length === 1, "collapsed by default");
click("a.expand-links");
andThen(() => {
assert.equal(this.$(".post-links a.track-link").length, 7);
});
await click("a.expand-links");
assert.equal(this.$(".post-links a.track-link").length, 7);
}
});