Skip to content
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

Refactor invoke queue into promise queue and support inline awaits #38

Closed
talkol opened this issue Oct 6, 2016 · 1 comment
Closed

Comments

@talkol
Copy link

talkol commented Oct 6, 2016

All lines in a test scenario are naturally asynchronous since the device has to perform each interaction and that takes time. In order to avoid the boilerplate of writing await before every line, we use a concept similar to what protractor does for its Control Flow.

Unlike protractor, our current implementation simply manages an invocation queue and then executes it until the test terminates.

This is not ideal. We need to switch to a pending promise queue like protractor.

In addition, we want to support a manual inline await in the middle of a test. The reason is that you might want to wait on something external, for example restart the simulator in the middle of a test.

@rotemmiz
Copy link
Member

rotemmiz commented Mar 6, 2017

async await api rewrite is now in master, and will be published soon with detox 5.0.0.
We ditched the Control Flow idea in favor of native constructs (Promises and async await). there is no invoke queue anymore. checkout the test project

@rotemmiz rotemmiz closed this as completed Mar 6, 2017
@wix wix locked and limited conversation to collaborators Jul 23, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants