samedi 28 mai 2016

Waiting for element by.css() in protractor

I have some code in which $scope.$broadcast triggers an event which executes an element.addClass()

I am trying to wait until the event has fired and the element.addClass is executed in my protractor test using

browser.wait(element(by.css('.activate')).isPresent,15000).then(function(isPresent){
      expect(isPresent).toBe(true);
    });

However, I get the following error

TypeError: Cannot read property 'getWebElements' of undefined

How do I wiat for the element with the class .activate to show up ??

Aucun commentaire:

Enregistrer un commentaire