diff options
Diffstat (limited to 'scripts/test/support.py')
-rw-r--r-- | scripts/test/support.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/scripts/test/support.py b/scripts/test/support.py index 7313169fa..3a6ed9bc2 100644 --- a/scripts/test/support.py +++ b/scripts/test/support.py @@ -199,8 +199,9 @@ def js_test_wrap(): # common wrapper code for JS tests, waiting for binaryen.js to become ready # and providing common utility used by all tests: return ''' - binaryen.ready.then(function() { + (async function __in_test_code__() { + var binaryen = await Binaryen() function assert(x) { if (!x) throw Error('Test assertion failed'); } %TEST% - }); + })(); ''' |