Closed aamorozov closed 7 years ago
Actually it's related to running nightwatch with config.json
instead of config.js
- the later one compiles all tests correctly using babel, while i'm not sure how to approach the same with config.json
as i never used it as nightwatch config. Does anyone have any suggestions please? As far as i know magellan itself doesn't support config.js
, by maybe someone found a workaround for that?
nvm was able to fix it, although support for config.js
will still be good to have.
Exists for me only when using the import/export(and other es6 sugar) in test cases. Using them in page objects, custom commands and custom assertions works just fine as the code gets compiled in the test cases with babel, so the issue is how to compile those test cases themselves.
Prior to running installed
babel-register
npm module as devdependancy and imported it in the test case by:but after trying to export the main test object
it throws an error on export
Everything works correctly with
module.exports = {}
Have anyone used/built test suite in testArmada with es6 modules?