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

78 questions
13
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,738
  • 5
  • 54
  • 92
11
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…
10
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…
6
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.…
5
votes
2 answers

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…
4
votes
2 answers

Issues updating desired_capabilities: Selenium WebDriver - Ruby

Super beginner here. Trying to update this test with Selenium WebDriver using Ruby the course I was going through uses the below which is deprecated. driver = Selenium::WebDriver.for :remote, desired_capabilities: :firefox The error I'm getting in…
3
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 the Start Session button, I got the error message “An unknown…
Maja Ucek
  • 51
  • 1
  • 1
  • 4
3
votes
1 answer

The method firefox() is undefined for the type DesiredCapabilities

I am trying to run the selenium grid in my machine and am getting the following for all the browsers at cap = DesiredCapabilities.firefox();: The method firefox() is undefined for the type DesiredCapabilities Below is my code package…
SUPARNA SOMAN
  • 2,311
  • 3
  • 19
  • 35
3
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.…
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(); …
JumpIntoTheWater
  • 1,306
  • 2
  • 19
  • 46
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
  • 5,669
  • 8
  • 37
  • 69
2
votes
0 answers

Selenium browser capability fontSize

Is it possible to change the fontsize of the browser through capabilities? if so how? manually we can set it from chrome>>Settings>> Appearance>> font Size.. so, wanted to set it at initial launch of browser and work. Had tried to find it in…
2
votes
1 answer

How to configure test case name in sauce labs for robot framework

I want to configure the name of the test case in Sauce Labs when viewing the test results. Currently the name that I am passing in the desired capabilities is popping up in the sauce labs and I am not able to understand which result is for which…
1
2 3 4 5 6