Protractor wait for angular application to be stable

扶醉桌前 提交于 2019-12-11 06:10:46

问题


I have an issue when running e2e tests with Protractor. It seems the whenStable is being called too early (a fraction of a second early).

I load the data via guards, populate the store and then the containers receive this data via selectors which then pass the data down to the components.

My application is built with Angular 5 and ngrx 4.

Is there a way to successfully get whenStable to trigger at the right time without creating my own function for checking if an element is present?

Edited this post as it's no longer a remote baseUrl issue. I now have it happening locally.

I have a test application that seems to work as expected, but in my larger application, everything seems to happen a little too early.


回答1:


Im not sure if I understood the question correctly. But using browser.waitForAngular(); will wait for all angular components to load.



来源:https://stackoverflow.com/questions/51859355/protractor-wait-for-angular-application-to-be-stable

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!