-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unnecessarily inserts await
#40
Comments
Is the condition inside |
I’ll set up a test repo. It could well be me doing something wrong. |
Here is a test repo. If the codemod is run against it, it will insert Related discord conversation (from July 2019) |
Oh you are testing intermediate states. My bad. Because tests were not async/await before, the more general assumption of this codemod is that the tests are now enabled with this feature. So I'm not sure there is a way to infer that you are testing intermediate states with the codemod sadly. Reference tests: |
Are you saying it’s not possible to fix? It’s a very annoying bug... consider a large app with a big team of varying ember experience... The ‘old’ (or less desirable) techniques for testing are still perfectly, so it’s still useful to run this codemod against an app that it has already been run on. But this means we then have to go through the diff (which could be huge, and remove all the |
I'm sure we could avoid adding |
I think so! Tbh I'm surprised nobody else has mention this before :D |
If this code mod is run on an app a second time (to update more tests that have since been added), then it does this:
This then breaks the test suite because
await click
waits for everything to settle, sowaitUntil
can't do it's thing.The text was updated successfully, but these errors were encountered: