Questions tagged [desiredcapabilities]

Introduction

Not all server implementations will support every WebDriver feature. Therefore, the client and server should use JSON objects with the properties listed below when describing which features a user requests that a session support. If a session cannot support a capability that is requested in the desired capabilities, no error is thrown; a read-only capabilities object is returned that indicates the capabilities the session actually supports. Learn more

Desired Capabilities : A Capabilities JSON Object sent by the client describing the capabilities a new session created by the server should possess. Any omitted keys implicitly indicate the corresponding capability is irrelevant

57 questions
12
votes
6 answers

BrowserStack: Unexpected error. Authorization required

I have two simple tests that are using RemoteWebDriver with ChromeOptions and EdgeOptions. Both these tests are using common code to set capabilities, including the browserstack.user and browserstack.key capabilities. Because I am using…
Mark Cooper
  • 6,214
  • 5
  • 51
  • 85
10
votes
2 answers

ChromeDriver(Capabilities capabilities) is deprecated

I use ChromeDriver 2.33 with WebDriver 3.6.0 and try to set default directory for file download. Map prefs = new HashMap(); prefs.put("download.default_directory", Vars.DOWNLOAD_FOLDER_ROOT); DesiredCapabilities caps…
7
votes
4 answers

Selenium not detecting the second window in IE

My application opens up a new window on clicking a button and i need to perform some actions in that window. But the response getWindowHandles() method of selenium webdriver has only one window id in it. This happens especially if there is a delay…
5
votes
1 answer

Selenium Chrome Options and Capabilities

I'm trying to automatically download a file with selenium. To do so I would like to set the default download directory and disable the download prompt. It doesn't seem to be working and the options I'm passing don't even seem to be registering.…
3
votes
1 answer

Getting error as "method chrome() is undefined for the type DesiredCapabilities"

Context: Getting error as method chrome undefined from the below code: package zapSeleniumIntegration; import java.lang.reflect.Proxy; import org.openqa.selenium.WebDriver; import org.openqa.selenium.chrome.ChromeDriver; import…
3
votes
1 answer

DesiredCapabilities is obsolete

I used to have the following code in order to run the driver as different user. public static IWebDriver RunIEAsDifferentUser(string User,string Password) { var capabilitiesInternet = DesiredCapabilities.InternetExplorer(); …
Yaniv Eliav
  • 1,070
  • 14
  • 30
3
votes
1 answer

org.openqa.selenium.InvalidArgumentException: Invalid capabilities using DesiredCapabilities

I have upgraded my Selenium framework to the latest version. During execution of the code, I receive the following exception: Exception: org.openqa.selenium.InvalidArgumentException: Invalid capabilities in alwaysMatch: unhandledPromptBehavior is…
3
votes
0 answers

Appium Desktop for Windows: How to call device's browser. Error "...com.android.browser not found"

TL;DR: When I have an emulator open, and I try to call the browser using Appium, I get an error saying that the browser isn't callable, even though there is a browser in the device. Not sure what it's called, so I can call it in Desired…
3
votes
1 answer

Apply proxy gateway in Selenium webdriver

My goal is to apply a proxy gateway (eg. geosurf.io) inside of the Selenium webdriver. I need to do it thru using DesiredCapabilities, since it seems DesiredCapabilities being the only way for plugging in proxy [gateway] (source).…
Igor Savinkin
  • 4,366
  • 7
  • 30
  • 57
2
votes
1 answer

Displaying an error: “Original error: ‘app’ option is required for reinstall” while start session in Appium

I’m new at Appium. I defined into ‘Desired Capabilities’ tab needed capabilities such as: deviceName, udid, platformName, platformVersion, appPackage, appActivity After I clicked on Start Session button, I got the error message “An unknown…
Maja Ucek
  • 41
  • 1
  • 4
2
votes
1 answer

What is the Desired Capabilities to handle this popup of Microsoft Edge?

There is popup which raised when trying to close tab of Microsoft Edge browser, Do we have any capabilities by which it can be control ? Or is there any relevant settings, from which it may not ask. Tried : …
2
votes
3 answers

selenium RemoteWebDriver opens but ChromeOptions are not passed to Selenium Grid

I have been trying to resolve a few issues with RemoteWebDriver and ChromeOptions using docker and selenium grid. The main issue is with the proxy but I half resolved that with a proxy pac file passing the pac file url as an arg into ChromeOptions.…
2
votes
3 answers

Is there any capabilities to set Firefox browser zoom level to some specific percent throughout script execution?

I'm using Firefox browser and i want to set the zoom level 90% while it executing the script. I have tried to set using JavascriptExecutor like - ((JavascriptExecutor)driver).executeScript("document.body.style.transform='scale(0.9)'"); Its working…
NarendraR
  • 6,770
  • 7
  • 35
  • 69
2
votes
1 answer

How do I correctly pass chrome capabilities into the default webdriver on Katalon studio

I'm currently trying to get a test running on Katalon Studio, and the specific outcome is determined by certain messages showing up in the browser console. I've managed to extract the console logs and can parse them easily enough, but I'm currently…
2
votes
1 answer

Is it possible to define custom capabilities for devices in Appium?

For instance, we have scenarios that require TouchID to be enabled and we have scenarios that require TouchID to be disabled. Appium itself doesn't expose such capabilities, so I'm wondering if it is possible to define custom capabilities for a…
Erik B
  • 35,941
  • 21
  • 106
  • 122
1
2 3 4