Open drptbl opened 8 years ago
Yes, this is a good point. When I first wrote it, I followed the examples, which seemed to be all async - which I personally find frustrating more often than helpful. Now that I've worked with it more, I'll see if I can make it synchronous. I'm pretty sure I remember looking into it and finding a way... surprised I hadn't implemented it already.
I'll work on this.
In the meantime, you can use the callback to coordinate, though I know that's annoying.
Would love to see this addition!
Hey @Rykus0, thanks for your great work last days.
There is one more issues which is the most "disturbing" one - I would say.
It looks like
visualRegression()
assertion is ran async. It's weird because all nightwatch.js assertions are ran sync. Is there any way to fix this?For example:
In example above: each
Finished visual regression checks!
log is done aftervisualRegression()
, so it's kind of "weird" that there is no assertion after first log, it's done while running second test case (so it's not sync for sure). Also it says "No assertions ran." after first test case, whilevisualRegression()
was ran there (still issue with async I believe). And summary prints only 1 failure while there was 2 failures actually.I think that most of this bugs are related to this issues with async issues in
visualRegression();
assertion.Thanks for great work, Cheers!