From 7c0f32662d58fe2c32b4e67c533012d3c965abf4 Mon Sep 17 00:00:00 2001 From: Rich Harris Date: Sun, 14 Jan 2018 00:10:20 -0500 Subject: [PATCH] remove async from new test --- test/common/test.js | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/test/common/test.js b/test/common/test.js index d880c5d2d..06407a4b8 100644 --- a/test/common/test.js +++ b/test/common/test.js @@ -311,17 +311,16 @@ function run(env) { }); }); - it('calls a delete handler', async () => { - await nightmare + it('calls a delete handler', () => { + return nightmare .goto(`${base}/delete-test`) .wait(() => window.READY) .click('.del') - .wait(() => window.deleted); - - assert.equal( - await nightmare.evaluate(() => window.deleted.id), - 42 - ); + .wait(() => window.deleted) + .evaluate(() => window.deleted.id) + .then(id => { + assert.equal(id, 42); + }); }); });