2

I tried to set up test using angular protractor. It works fine when I use browsers of desktops, But failed with mobile browsers. Here is the set of protractor.

    seleniumAddress: 'http://hub.browserstack.com/wd/hub',
    capabilities: {
       'browserstack.user' : 'user',
       'browserstack.key' : 'key',
       'browserstack.debug': 'true',
       'browserstack.local' : 'true',
       'platform' : 'MAC',
       'device' : 'iPad mini Retina'
    },

And I got the error like this in the log of browserstack when using iphone:

    <Error>
    <Code>AccessDenied</Code>
    <Message>Access Denied</Message>
    <RequestId>6A1E5288B65A8A2C</RequestId>
   <HostId>
    ixGtp6t7yQWYa7cjkNqmaXLEHTXeKklSkf+Jmg9vnA/a+RYUfzUhJuNykqKAwOuoA3o1eQA9M9c=
   </HostId>
   </Error>

Error like this when using andriod

   01:23 0 Injecting JavaScript-argsbodyscriptreturn (function () { var el =    document.querySelector(arguments[0]); var callback = arguments[1]; try { angular.element(el).injector().get('$browser'). notifyWhenNoOutstandingRequests(callback); } catch (e) { callback(e); } }).apply(null, arguments);⇒ 
   **This is feature will be implemented soon!**

Any one can give me some ideas about this?

alecxe
  • 462,703
  • 120
  • 1,088
  • 1,195
Julie
  • 21
  • 1
  • Feature-related questions about products should be directed to the company or vendor you're using; if there was a configuration error that was in open-source/standards-based code, then we can probably help. However, Stack Overflow isn't focused on (or really even able to) offer product-specific support. – markthethomas Jan 09 '15 at 18:18
  • The drivers used by browserstack to drive mobile devices in automated tests are not working correctly, and it's not specific to browserstack. It especially concerns async script execution, script arguments types, locators working or not depending on drivers, document building delay which forces to add waits in tests. – atondelier Jun 02 '15 at 14:47

1 Answers1

0

You need to supply username and API key in request URL.

In your code:

http://hub.browserstack.com/wd/hub

It should be:

http://[username]:[api_key]@hub.browserstack.com/wd/hub

without [] brackets.

Also, you can read browserstack document for further understanding. https://www.browserstack.com/automate/ruby

Aravin
  • 6,605
  • 5
  • 42
  • 58