Can't get test through the end with protractor <p>I have simple test doing login and trying to check if it's success:</p> <pre><code>describe('My Angular App', function () { describe('visiting the main homepage', function () { beforeEach(function () { browser.get('/'); element(By.id("siteLogin")).click(); }); it('should login successfully', function() { element(By.name("login_username")).sendKeys("test@email.com"); element(By.name("login_password")).sendKeys("testpass"); element(By.id("formLoginButton")).click().then(function() { browser.getCurrentUrl().then(function(url){ expect(url).toContain("profile"); }); }); }); }); }); </code></pre> <p>It goes well until that last part where I'm checking URL, and in <strong>Selenium Server</strong> I get:</p> <pre><code>INFO - Executing: [execute async script: try { return (function (rootSelector, callback) { var el = document.querySelector(rootSelector); try { if (window.getAngularTestability) { window.getAngularTestability(el).whenStable(callback); return; } if (!window.angular) { throw new Error('angular could not be found on the window'); } if (angular.getTestability) { angular.getTestability(el).whenStable(callback); } else { if (!angular.element(el).injector()) { throw new Error('root element (' + rootSelector + ') has no injector.' + ' this may mean it is not inside ng-app.'); } angular.element(el).injector().get('$browser'). notifyWhenNoOutstandingRequests(callback); } } catch (err) { callback(err.message); } }).apply(this, arguments); } catch(e) { throw (e instanceof Error) ? e : new Error(e); }, [body]]) </code></pre> <p>and also I get:</p> <pre><code>Failures: 1) My Angular App visiting the main homepage should login successfully Message: Error: Timeout - Async callback was not invoked within timeout specified by jasmine.DEFAULT_TIMEOUT_INTERVAL. </code></pre> <p>My <strong>protractor-conf.js</strong>:</p> <pre><code>exports.config = { seleniumAddress: 'http://localhost:4444/wd/hub', baseUrl: 'http://localhost:8080/Mysite', capabilities: { 'browserName': 'firefox' // muste use firefox because I can't get .click() to work in Chrome }, specs: [ 'spec-e2e/*.js' ], framework: 'jasmine2', jasmineNodeOpts: { isVerbose: true, showColors: true, defaultTimeoutInterval: 30000 } }; </code></pre> <p>I appreciate any help on this one. Thanks</p>