ng2-ace-editor
ng2-ace-editor copied to clipboard
Ng2-ace-editor protractor e2e tests not working
Hi,
There is an issue with ng2-ace-editor and protractor e2e tests. Tests does not work for pages in which ng2-ace-editor is used. As soon as test navigates to a page in which ng2-ace-editor is used, it just freezes. Seems like ng2 ace editor is not allowing browser to finish synchronizing, and that is the cause why protractor still thinks that page is loading.
Is this a known issue already?
Best regards, Valters
Hi, I'm going through the same issue. Did you find any help?
Hey,
Haven't found any solution yet.
it look likes there's a pending task in ngZone that is taking too long time. It should come from ace itself. Maybe we should run this outside of the zone ?
I would do things like that :
import {browser} from 'protractor';
beforeEach(() => {
browser.waitForAngularEnabled(false);
});
But depending on some of your tests you will need to wait for changes. You can use browser.wait() to wait for a condition.
I have unit-test with protractor running and they seem to work fine at my end. My tests also write to the editor and even change the theme. A look at your test code might be helpful. Also, is the freeze happening only during the tests?
We just found the same issue in our protractor e2e tests. They get stuck on views where ace-editor is used because angular zone never gets stable.
This means it should be changed, so that the ace editor runs outside of ng zone
I suspect that 626a7229b5a8683b28075f1bf0c1b3259e335b88 might've fixed the issue. I'm still experiencing it when running Protractor tests in a docker container running alpine linux. Will try a different Dockerfile setup