Update execa to v6 (and update scripts to ESM)#502
Conversation
| } | ||
|
|
||
| console.log('codemod ran successfully! 🎉'); | ||
| process.exit(0); |
There was a problem hiding this comment.
Does this test have actual assertions? Or is it like a smoke test?
There was a problem hiding this comment.
so... unfortunatly the git diff didn't quite fiture out that this was a move-file change. I didn't alter the way the test was working, I'm just changing it to .mjs to make it work with the new execa version.
but from my understanding, this does have an "assertion". If you look at the bit that is calling diff on two folders: https://github.com/ember-codemods/ember-angle-brackets-codemod/pull/502/files#diff-f28f8437ce5be5f9a77df8786489b7522a29c3377687b4feb491253b7044a4e2R21 you'll see that it's testing the "app" folder against a known output folder. That comes from the fixtures folder: https://github.com/ember-codemods/ember-angle-brackets-codemod/tree/master/test/fixtures
essentially I've seen people setup codemod tests like this before and it's just testing an input folder against an expected output at the end, and if they match it's good 🎉
There was a problem hiding this comment.
I hope that answers your question 🎉
Because v6 of execa is ESM only we need to update our scripts that are using it to also be ESM. This PR does that 👍