Questions tagged [c#]

Use for questions about testing using C#. This can include unit tests, integration tests, UI tests. If a programmed test uses C#, and the question relates to testing rather than to code, the C# tag should be used.

Filter by
Sorted by
Tagged with
2
votes
1answer
554 views

Coded UI Test Explorer execution order?

What is the order of test cases execution in Coded UI? I have my test cases created in Coded UI and they all follow a naming convention e.g. _, so my test cases name looks like: ...
2
votes
3answers
180 views

Personal framework project website [duplicate]

I am a selenium C# developer, and have just recently conducted an interview with a company. During this process I was asked a lot of questions about "hypothetical" framework questions, and how I would ...
2
votes
2answers
4k views

Execute a particular test using command prompt and Selenium, NUnit, Test cases written in C#

I have written a number of test cases in C# for UI which uses Selenium Webdriver (I am new to Selenium). I would like to run a particular test case out of N number of test cases through command ...
2
votes
3answers
752 views

Testing using Selenium

I am a software architect we use selenium tests with nunit and c# i am trying to run jmeter load testing using firefox jmeter recorder (for blazemeter) i was sure selenium has its own cross ...
2
votes
2answers
1k views

Looking for a HEADLESS C# Selenium automatic nightly regression test solution

The WHY: I am looking for options and possible full solutions if someone has already done something similar. I am testing web-based applications using C# Selenium with VS2015 by writing tests that ...
2
votes
1answer
8k views

How to get a grid row count with Selenium in C#?

Hello I am currently trying to figure out how to get the count of how many rows are displaying in an HTML Grid on a page. From researching several stack exchanges some people reference GetXPathCount ...
2
votes
2answers
983 views

Opening Multiple windows of firefox in the same test case

My question might sound very odd to you all but just wondering if this is possible for us. Okay so I have written 10 cases for my login page in selenium using C# .net. But they take quite a lot of ...
2
votes
1answer
365 views

Programming language for testing GUI written in C#

Our GUI for our Windows application is written in C#. I want to write some automated regression tests. Which programming languages would work? Have in mind: I do not have access to source code. I ...
2
votes
1answer
11k views

How to find dynamically created elements in drop-down list based on input entered using Webdriver and c#?

I'm trying to test a page that has an input but really its a drop down list. The user enters text and then a dropdown appears based on what the user inputted. They are groups that are in the database. ...
2
votes
1answer
130 views

Retry in nunit not working when test times out

I am using Timeout attribute for nunit test case as below: [Test, TestCaseSource("TestCases"), Retry(2), Timeout(10000) public void test(){ // Some code that runs for more than 10 seconds } I ...
2
votes
1answer
70 views

Select elements within <div> and <iframe>

We started test automation on our web app (ASP.NET). We should've done it ages ago and the meantime the app has become complex so our Selenium progress is very slow. I'm completely new to Selenium and ...
2
votes
1answer
51 views

How to update C# version in Ranorex Studio?

My project in Ranorex Studio (v8.3.1) is using .NET Framework 4.5.2 and C# 5.0. I want to leverage the features of newer C# versions e.g. String Interpolation. So I want to upgrade my Ranorex Project ...
2
votes
1answer
264 views

Automated test generator

After a long road with Randoop.NET as a unit test suggestion tool, my developing team has decided to upgrade to a commercial tool which will provide us a full unit testing framework for professional ...
2
votes
1answer
807 views

Error - System.Invalid_Exception - Unknown Error Cannot Focus Element

I get the above error message on running this code: using OpenQA.Selenium; using OpenQA.Selenium.Chrome; using OpenQA.Selenium.Firefox; using System; using System.Collections.Generic; using System....
2
votes
1answer
4k views

GeckoDriver not working in C# for Firefox browser

I'm trying to run some unit tests using Selenium Webdriver and C#.Net for Firefox browser but I was unable to do it (Chrome and IE11 browsers are working smoothly). Here is the info I gathered: OS: ...
2
votes
1answer
393 views

Unable to run tests for Appium on Visual Studio 2015 due to Timeout

I am trying to run my script on Appium and I always fail tests because of an error on my unit test: Test Name: Addition Test FullName: AppiumTest2.UnitTest1+BasicScenarios.Addition Test Source: ...
2
votes
1answer
968 views

Selenium in VS 2015/C#: Problems with ordered unit test

I'm using unit tests in VS to create my tests, and naturally I ran into the challenge that unit tests should not be dependant on the run order. However, since my tests are actually functional tests, ...
2
votes
2answers
724 views

Explicit wait with more methods to same element

I have a few questions related to explicit waits: Is it possible to use more methods to same element? What combination of them I can use ? Why I still have exceptions with stale element and similar ...
2
votes
3answers
690 views

Clicking on a Xpath

I have a back button on my web page which I need to click on from different places. In one page the back buttons xpath looks like: //property-list/ion-header/ion-navbar/button In another other page ...
2
votes
2answers
1k views

Selenium FindElements() hangs sometimes

I have a problem when trying to find many elements in a page. Basically i have 20 identical pages, with slightly different data. Think 20 excel sheets. Page 1 50rows, page 2 100 rows, etc.. each row ...
2
votes
1answer
16k views

How to save a copy of web page DOM using selenium webdriver and JAVA/C#

I need to write a crawler that crawls throughout exercises available on my website (1200 exercises) and save a copy of DOM in my local as I have to use that DOM to create an exercise DVD. Can anyone ...
2
votes
1answer
117 views

Data Driven Framework Limitation

I am currently using a data driven framework for my automation testings with Excel. When I have more than 255 characters, in my Excel cell my tests fail. Are there any other alternatives with Excel ...
2
votes
1answer
810 views

How to handle dynamic IDs in Selenium webdriver using C#

I am automating our application and it has ids that are dynamic in a form. What happens is when I click on a button to add another form within the page, the HTML shows below: <table id = "...
2
votes
3answers
763 views

How to capture image from webcam in selenum webdriver c#

I have to capture image using webcam and save as profile image. Below is the screenshot of my flash application . Below are the steps I have to perform: Click on allow click on capture click on ...
2
votes
1answer
84 views

Is it possible to Serialize a UITestControl (when using Coded UI)?

Let me start by saying that currently I am not using the record and playback features of Coded UI, nor am I using the UIMap features. I am trying to speed up the performance of my Coded UI tests (...
2
votes
1answer
833 views

Issue with Radio buttons selection in Coded UI

I am using Coded UI for creating some test cases for a web application, while doing the same I have encountered an issue. I am not able to select a Radio Button using their Displayed Text, however if ...
2
votes
1answer
1k views

Accept SSL certificates in Selenium Opera C#

I am trying to launch an Opera web driver, but whenever I go to the homepage of the site under test, I get certificate errors. I have tried using the CapabilityType.AcceptSslCertificates = true: ...
2
votes
1answer
1k views

Problem with selecting an Element from a div using nested FindElement option

I am creating a test for presenting a demo to my management and client using Selenium WebDriver in C#. In this test I need to find an element (a radio button), but for that I want to use the nested ...
2
votes
2answers
3k views

Testing the Downloading/Uploading of files with Selenium IDE/WebDriver/Other?

In a series of applications my team is building we would like to test our import and export functionality which requires the respective upload and download to be automated. The functionality is ...
2
votes
1answer
116 views

Clicking a Non Existent DOM item

EDIT: I used mouse events and did get a working solution that is pretty ugly :). So I may be at a point that automating this page will not be possible. I am trying to click a popup menu that appears ...
2
votes
1answer
101 views

wcf client test in vs 2010 tools

wcf client test I am using wcf test client in vs 2010 tools. First when i started tool, values came with null. I want to change value's dropdownlist with my default values. How can i do it?
2
votes
1answer
777 views

CodedUI : The Browser gets closed as finish testing without keeping for testing further steps

I'm working on a CodedUI project to check on a Web Solution. There, when Im testing for launching the site (as in launching the web URL), I am facing an issue with closing the browser as it finish ...
2
votes
2answers
5k views

How to create and write Excel .xls file using C#

I have few tests which run three times and their average is calculated through c# code. I am able to write the three test times and their averages to the xls file if I create the file beforehand in ...
2
votes
1answer
139 views

Passing parameters between tests with RestSharp

As I'm getting more familiar with the RestSharp client library for my API testing I'm confortable with using it for single API response checks e.g. checking a status code is correct, or that the ...
2
votes
3answers
2k views

Selecting element value from drop down list with selenium using POM

I'm trying to make simple test to register in website - https://www.midomi.com/. I'm using c# and selenium but have stuck in selecting values from dropdown list using Page object model. My project ...
2
votes
2answers
340 views

Automation tool for testing integration of a Web application with a desktop application?

I am new to Test automation and would like to try my hand at automating a web application project. This web application gets its data from a desktop application (on syncing). I was thinking that ...
2
votes
0answers
23 views

JQuery Not working after updating NUNIT to 3.7

I have used to find an element using jQuery select0r. This is how am trying to find out the element. var linkDom = new DomElement(DomElementType.JQuerySelector, string.Format("{0} a:icontains(\"{1}\")...
2
votes
2answers
980 views

What is the use of section in siteprism? Is it similar to page object model of selenium webdriver?

I have been doing selenium automation in C# for almost 1 year. I need to learn siteprism using capybara. When I was going the documentation of siteprism i can't relate section with page objects. I ...
2
votes
2answers
311 views

Close a one windowHandler at the Webview

I am writing scripts to automate a hybrid application. On my app I have two windowHandles. For example, after performing some actions when I execute below code I get "2" windows as the windowHandles ...
2
votes
2answers
9k views

Downloading a file using Selenium Webdriver C# not working

I am using Selenium Webdriver with C# for creating Automation test cases and have encountered an issue i.e. not able to automate the file download windows pop-up. On doing search over web, I found ...
2
votes
1answer
582 views

Skipping iteration for test cases [closed]

This is a simulation of the test suite I want to run with selenium webdriver. Running through everything will generate 128 test-cases which are too ambiguous. I plan to reduce it to 32 by only ...
2
votes
0answers
642 views

Passing session while switching control to a pop-up window [closed]

I am trying to choose a date by clicking an image which results in a pop-up window with a date picker in it.But when done through selenium the session expires and the login page appears in the pop-up ...
2
votes
0answers
300 views

How can I automate testing of HTTP requests? [duplicate]

Possible Duplicate: Is there a captureNetworkTraffic implementation in Selenium 2 via webdriver? I'm using Selenium2/C# to run automated tests of a web app. I need to test the HTTP requests sent ...
2
votes
3answers
6k views

How to check if the button is disabled

I have a problem how to check if the button is disabled. If button is disabled and I use Assert.IsTrue(driver.FindElement(By.XPath(OKButton)).Enabled, "OK button is disabled."); it is not finds ...
1
vote
3answers
485 views

Unit Test - Testing API Methods

I was reading the following article Unit testing an API This article is about unit testing an API and the methods on a class through the interface. What I do not seem to grasp is the fact that in my ...
1
vote
4answers
4k views

C# WebDriver StaleElementReferenceException

I've been hitting my head against the wall trying to understand this and search Youtube, MSDN and this site but I can't move further with my scripts because of the StaleElementReferenceException. Here ...
1
vote
3answers
4k views

How to automate multiple selenium test cases where one test case is dependent with another test case?

SCENARIO OF TEST CASE 1: Opens the browser Enters the username password Goes to home page Closes the browser SCENARIO OF TEST CASE 2: Home page should be testes so the baseurl for this case is ...
1
vote
1answer
3k views

Sikuli and it's effectiveness with .NET

I am researching a proof of concept for the automation tool Sikuli, and I work primarily at a .NET shop. I see a lot of videos using this product with Java and Eclipse. My question is simply: Does ...
1
vote
2answers
13k views

Set date in datepicker using Selenium WebDriver and C#

I am using Selenium WebDriver. I have datepicker on a web page, and I want to set a date into that control. I am using .SendKeys("12/31/2015"), but it does not select that date on the screen. It ...
1
vote
2answers
4k views

How to configure HtmlUnit Driver

I clearly missed a step trying to get HtmlUnit driver working with my app. I am getting the following exception: OpenQA.Selenium.WebDriverException was unhandled HResult=-2146233088 Message=...