Set user-agent for remote webdriver?
Is there any way to set the user-agent for a remote webdriver?
I'm managed to set it for local Firefox and Chrome instances - however, when I use the remote webdriver, it seems to ignore it?
@victorhooi you can set the browser parameter. There is an example here: http://splinter.cobrateam.info/docs/drivers/remote.html#useing-the-remote-webdriver
@andrewsmedina Yes, we're using that to get the actual different browser engines (e.g. Firefox verus Chrome versus IE).
However, we'd like to actually set the user agent - e.g. to something like:
Mozilla/5.0 (iPhone; U; ru; CPU iPhone OS 4_2_1 like Mac OS X; ru) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8C148a Safari/6533.18.5
(In our case, it's to test some mobile user agent redirections).
Is this possible?
Closing this issue due to age.
For future reference, the user agent for a remote webdriver instance can be set by passing in an Options object with the user-agent argument set.