Questions tagged [selenium-webdriver-c#]
C# Flavor of the Selenium Webdriver Library
60
questions
0
votes
0answers
17 views
Extent report(4.01) for selenium webdriver with C#
I am trying to generate report with ExtentReports(4.0) in Visual Studio C#. When i run a test case the html report file is not being generated. I am not sure what is wrong in my code. I think the ...
-2
votes
0answers
54 views
Assert Fails Though Text Values available in that XPath
I'm working in selenium with c#
Assert is not working though xpath is given correctly. xpath shows only one item.
It was working correctly quite sometime back.
Here is my piece of code.
Assert....
1
vote
1answer
57 views
Keyboard ArrowDown in listbox using Selenium with C#
I'm working in selenium c# automation, I'm trying to traverse down in list box values. <ul> and <li>. I have tried many options in trial and error. The kind of code I'm trying to use is ...
1
vote
1answer
44 views
Access is Denied Issue thrown at ChromeDriver Initiation step
Azure DevOps is triggering and running tests on a VM.
All my tests are working fine on local machine.
On VM, While trying to launch Chrome browser using ChromeDriver and WebDriverManager, tests are ...
1
vote
1answer
69 views
Not able to verify the downloaded file with Chrome WebDriver running headless
We are trying to verify the downloaded file in headless mode with C#, the file is downloading but not saving in the download path, so my test script is failing.
Any idea for this?
The code is below
...
0
votes
1answer
52 views
Unable to connect to Remote Server using Selenium Chrome RemoteWebDriver
public static IWebDriver UserMultiUserSignIn (IWebDriver driver, string port, string hostName, string password, string Username)
{
string name = Dns.GetHostName();
ChromeOptions Options = new ...
1
vote
1answer
76 views
Invalid Session id (Connect Failure) randomly when running automated tests
I've been new to automated test creation and have been dipping my hands on it recently. Every test seems to be running successfully individually except whenever I run them all together sequentially, ...
0
votes
2answers
53 views
How can I verify that saved data is displayed corrrectly using Selenium + C#?
<p class="details-info-block__text"><span class="details-info-block__label">Business Address 1:</span> 1010 Priority Way West Dr</p>
I want to verify the address value (e.g. "...
0
votes
1answer
29 views
Selenium chaining IWebElement actions in C# [duplicate]
[FindsBy(How = How.XPath, Using = "//input[@id='Username']")]
private IWebElement txtUsername;
public void EditTxtUsername(string text)
{
txtUsername.Clear();
txtUsername.SendKeys(text);
}
...
0
votes
1answer
75 views
How to run automated selenium test scripts using C# in AWS Lambda and integrate them Amazon CI/CD pipeline
I have been give an task by a faculty member in which I have to run my selenium automation scripts written in C# using Visual Studio under the .Net Core on AWS Lambda and also I have been told to ...
0
votes
0answers
34 views
Using Selenium Webdriver Python Scripting file picker popup is not getting displayed using MACOS
Hi I have been trying to automate a page using Selenium Python on MACOS. And in one of the page there is a file picker popup that is supposed be displayed to upload files. Manually when running I get ...
4
votes
2answers
932 views
Using Python Selenium Not able to perform click operation
I am automating for the following page on CHROME Browser
https://study.yupl.us/studies/5d5a64aa8b5bb92fb776753b?auth=false
Here I'm able to identify the unique element from the console for the XPATH ...
0
votes
1answer
57 views
Teardown of Multiple Threaded Tests with Selenium
I'm trying to run multiple test cases with Nunit in C# in which every test needs its own Selenium Chrome Driver.
Before it was threaded, I handled the chrome driver with [Setup] and [Teardown] like ...
0
votes
1answer
22 views
Selenium to test Dygraphs
Is it possible to use selenium(C# bindings) to write automated tests for testing Dygraph charts?
If selenium does not support this? Are there any other tools which can be used?
http://dygraphs.com/
...
0
votes
2answers
58 views
Unable to select <li> element from a <ul> list
How do I select a "li" element from a "ul" tag list?
This is my current code
vtenants.VT_USDelselectfld.Click(); //Clicks field to display the dropdown
Thread.Sleep(500);
IList<IWebElement> ...
-1
votes
1answer
42 views
Selenium with C#
I am new to C# with selenium and visual studio,I have some experience only in Selenium with java in eclipse.
Here my doubt is that in eclipse we used to configure the packages for every new projects ...
1
vote
0answers
112 views
How can i use an existing existing chrome browser instance in selenium C#
How do I use an existing chrome browser in selenium C# ?
Currently I have the following but it always creates a new window
SessionId sessionId = new SessionId("");
var driver = new phantomJSDriver();...
1
vote
1answer
100 views
Selenium C# Using relative XPath inside the wait.Until()
How do you use a relative xpath inside of a wait.until?
For example, the below will work:
elementA.FindElement(By.Xpath(.//div));
However, putting a 'FindElement' inside of the wait.Until() ...
1
vote
0answers
1k views
How to configure proxy settings for chrome in selenium c#
I want to configure the proxy settings for chrome web driver by using selenium 3.141.0 version in c#.
var co = new ChromeOptions();
Proxy proxy = new Proxy();
ProxyIPAddress proxyIP = JsonConvert....
1
vote
1answer
112 views
How can I keep this framework scalable?
I am developing an automated test suite for regression testing using Extent Reports, Selenium WebDriver and C#. The tests are confined to a single Visual Studio console app. What I have right now ...
0
votes
3answers
62 views
Trouble deleting NaN in input field
I'm using Selenium to fill in a web form. The fields there have their default values, usually it's 0. If I issue the command
Driver.chrome.FindElement(By.Id("ID_of_my_element")).Clear();
the value ...
2
votes
1answer
42 views
Strange exception when executing tests
I write test automation using Selenium and C#. I use the Page Object Model consistently. And have had a random bug crop up in my code:
Type of member 'IWebDriver' is not IWebElement or IList
0
votes
3answers
40 views
should tests be run on the same machine/server the website being tested is located on? Selenium testing
Are there any rules or articles which discuss where tests should ideally be run? Specifically smoke tests. Smoke tests should run quickly after someone checks in new code. If you are looking for fast ...
0
votes
0answers
489 views
Handle windows authentication pop up on Chrome using AutoIT
I am trying to handle the basic authentication pop up for my Selenium webdriver scripts using AutoIt in Chrome. I am using following AutoIt script:
WinWaitActive("","Chrome Legacy Window","120")
If ...
-1
votes
1answer
6k views
C# - Element Not Interactable error [closed]
I am unable to select a value from dropdown for span type
I've got the error
Element Not Interactable Exception
in Selenium .
I am running Selenium in C#.
0
votes
2answers
96 views
mstest using testsettings file on bamboo?
I am using bamboo to run an mstest task. The mstest task runs selenium code and generates an extent report. I am wanting to pull the results from that report as an artifact in Bamboo.
I accidentally ...
0
votes
0answers
108 views
mstest using runsettings file on Bamboo
Is there a way to make sure mstests uses the runsettings file on our bamboo server? I just had to add it to my project to have my results in a consistent folder. This worked correctly from Visual ...
0
votes
0answers
179 views
Selenium C# Tests on Various Browsers
I would like to run my tests on multiple browsers but NOT in parallel. I want to provide a pop up to the user to choose which browser (IE, Chrome, Firefox) to execute all tests on when first started.
...
0
votes
0answers
67 views
Changed Selenium Framework
I am using this Selenium Set-Up in an older Project. (later called "Old-Project")
Now I want to migrate this test to a Project with this Set-Up: (later called "New-Project)
I am using a code sample ...
1
vote
5answers
2k views
Get Driver Version using Selenium with C#
I am testing with C# & Selenium & Selenium.Chrome.WebDriver (Nu-GET Package, Version 2.44.0). Now I am searching for a Method which gives me the actual Version of the current runnig driver.
...
0
votes
0answers
28 views
System.ArgumentException : Cannot use How.Custom without supplying a custom finder type
I am a beginner in Selenium c#. I installed Visual Studio 2017 Community version & started created framework. So i created 2 files, 1 Page Factory(POM) file, 2 Test Case. Now if i run Test case, ...
1
vote
2answers
257 views
Can not find getPageSource method in visual studio 2017
I am using Visual Studio 2017 and found that class ChromeDriver does not contains method getPageSource(). Does anybody knows why?
using System;
using System.IO;
using OpenQA.Selenium.Chrome;
...
0
votes
0answers
43 views
Regarding Driver and JavaScript executor using for scroll down - using selenium and C#
The driver and Javascript executor runs successfully but there won't be any action. When I checked the driver values, I saw errors regarding Application Cache and Network Condition.
The code i am ...
0
votes
2answers
117 views
Unable to find Dynamic Xpath
I am unable to find dynamic xpath for below code
<input class="login_button" type="submit" tabindex="3" id="@COMMAND_EVENT@" name="@COMMAND_EVENT@" value="Submit" style="top: 20px; left: 360px; ...
2
votes
2answers
688 views
Selenium c# how to handle multiple “Save As” dialog?
I am testing opening multiples "Save as" dialog browser windows to make sure each dialog will download the correct file.
As a workaround I am sending user's keyboard keys to control a dialog. But it ...
1
vote
1answer
592 views
How to find IWebElement in other IWebElement with Selenium Web?
I'm trying to get some IWebElement in other specific IWebElement which I find, but it doesn't work.
Here I find all of the repeated HTML blocks, it works OK:
List<IWebElement> ...
1
vote
0answers
760 views
Selenium c# how to get a window title by searching by its Handle Id?
In order to get a browser window title, the web driver must switch to the window by its Handle id:
string title = driver.SwitchTo().Window("Handle ID").Title;
I am testing opening multiples windows ...
4
votes
2answers
2k views
How to select the second tr of my HTML?
The code below works but it only selects the first tr:
My HTML:
<script>if(''!='') { document.Form2.endereco_ip.value='';}</script>
<div style="font-size: 10pt; font-weight: bold">...
3
votes
2answers
2k views
Selenium Web Driver, ExpectedConditions [deprecated] alternative
The selenium web driver seems to be indicating that OpenQA.Selenium.Support.UI.ExpectedConditions method is now deprecated, I would humbly ask for some assistance in rewriting the below statement, ...
2
votes
1answer
44 views
Selenium, updating rows, refreshing, stale items
I have a table of charges, I am creating an array of elements of the rows. I go through the line items and zero them out.
The issue is, each of these are handled by modal windows. It pops up, I ...
2
votes
3answers
837 views
(C#) Selenium: How to extract information from html and write to a variable
I want to know how to get the HTML tag information and write to a C# project variable. Remember that I can not change the HTML because I do not have access.
In the example below, it is necessary to ...
1
vote
1answer
107 views
(C#) Selenium: How do I choose an option within a ComboBox?
How do I select the "C" option of my ComboBox "opcao_pesquisa"?
<form name="Form1" method="post">
<input type="hidden" name="operacao" value="1">
<input type="hidden" name="d" ...
2
votes
2answers
62 views
Selenium: How do I use the button of my HTML in WebElement?
How do I locate my button that has the text Pesquisar > in my Selenium WebElement?
My HTML:
<div style="font-size: 10pt; font-weight: bold">Portais
</div>
<hr>
<form name="...
1
vote
1answer
549 views
Unable to select element when element is in span than select Selenium c#
I am trying to select an element from dropdown with text as Ad. My page has a telerik dropdown and this is the HTML Code.
I am running following code:
SelectElement IDdropdown = new SelectElement(...
0
votes
2answers
752 views
Compare a screenshot with saved image on Devops build server
Background
When releasing a C# MVC website through Devops release management the bundling failed. This caused the CSS file not to load on the released website, causing the UI to render incorrectly.
...
0
votes
1answer
826 views
C# Selenium - How to write a conditional statement with multiple elements/xpaths
I have a problem and having trouble to finding a solution.
Problem Statement:
Navigate to a webpage and check if three checkboxes are selected. If not, I'd like to select them (if only one is ...
1
vote
1answer
707 views
Selenium Webdrive object retains page source from previous page (of CRM). But page url is current
I am writing automation scripts for Dynamics 365 using Selenium Webdriver with C#.
All is good till I login and visit first page (a list).
Test script clicks on one item in first page and page ...
0
votes
1answer
1k views
Unable to click button with selenium webdriver using C#
I am having trouble with clicking a button within a modal using Selenium and C#.
The button is for a photo upload, and for some reason the element that is select-able (tested with JS in the console) ...
1
vote
2answers
545 views
Unable to locate element (Selenium, Sharepoint2010) [closed]
I'm new in QA.
I'm using VisualStudio 2017 + Selenium WebDriver.
I'm Trying driver.FindElementById in Sharepoint 2010 web page.
It is part of the DOM:
<div id="ctl00_MSO_ContentDiv">
<a ...
0
votes
2answers
145 views
How to check a checkbox which is not visible?
I need to check a checkbox, but am not able to do that. It's giving the error:
Element is not visible
This is the element:
<input _ngcontent-c5="" class="lb-checkbox ng-untouched ng-pristine ng-...