I think you need you give the official support once in a quarter or at-least once in a half yearly. Last update was on January 2014. Browsers are upgrading rapidly, and I want to use the CodedUI to the cross browser test, i need some confidence that it should support on current available cross browsers.
Hi this seems to be a nice replacement for the Feature pack2 back in Vs2010 which just support Firefox 3.6 but this is great start to playback CUIT stuff against WebDrive whihc i think eliminates the burning issues open Desktop session
Great add on to Coded UI Testing framework, but unfortunately it seems there are still a lot of issues surrounding it, and lack of support is not helping. Some issue and confusion I've spotted from other users while browsing for solutions with my own issues is with simple installation of the product. Additionally, the version support for different browser is all over the place. I understand that it is also down to individual browser suppliers but i believe issue like those should be dealt prior to release of any product. Overall still a great add on, just requires attention to above issue in order to get 5 stars from users. Looking forward to next update.
You really might want to point folks to a sample or two about making use of this functionality. Without some kind of working example that customers can work with, it's really not going to gain any traction.
For those curious about being able to swap between browsers at will, it turns out you need to set an environment variable in order to do that. I found some now out-of-date material at http://msdn.microsoft.com/en-us/library/jj835758.aspx that has a bit of detail on that.
Overall, this is an improvement over being able to run only on IE, but the amount of work that is needed to do so can be time consuming. For example - if you have anything dynamic on your pages (say, part of the window title changes based on a previous action), you're not going to have a great deal of luck using this.
Also, having to code your own "WaitForAjax" solution is a big hurdle to clear.
Based on what I see so far, my team will be staying with our current Selenium WebDriver framework. We have more control over flow, control detection and selection, and dynamic content handling than CUI has.
Hi, do you still only support firefox 33, or will these tests run on newer versions? We are having issues as firefox keeps updating (even though we have removed the auto-update option), with the result that the tests stops running on firefox. (nothing happens, the test-runner keeps running for a long while giving no error messages, until timing out. Can you guys tell me what version of firefox you have the tests running in?
Hi Abhitej, and thanks for the response. I found the latest selenium binaries (from here: http://www.seleniumhq.org/download/ ) . I am now running the latest selenium binaries (2.45) and latest firefox(37.0.1). Chrome and IE runs ok, but when I get to firefox, I get this error:
Object reference not set to an instance of an object.
at Microsoft.VisualStudio.TestTools.UITest.Extension.CrossBrowserProxy.FuncInvoker.InvokeMethod(Func`1 function)
at Microsoft.VisualStudio.TestTools.UITest.Extension.CrossBrowserProxy.ProxyFirefoxDriver..ctor(ProxyFirefoxProfile profile)
at Microsoft.VisualStudio.TestTools.UITest.Extension.CrossBrowser.BrowserServices.FirefoxBrowserService.InitializeWebDriver(String args)
at Microsoft.VisualStudio.TestTools.UITest.Extension.CrossBrowser.CrossBrowserService.<.cctor>b__1(String args)
at Microsoft.VisualStudio.TestTools.UITest.Extension.CrossBrowser.CrossBrowserService.Launch(Uri uri)
at Microsoft.VisualStudio.TestTools.UITest.Extension.CrossBrowser.CrossBrowserFactory.Launch(Uri uri)
at Microsoft.VisualStudio.TestTools.UITesting.BrowserWindow.LaunchPrivate(Uri uri)
at Microsoft.VisualStudio.TestTools.UITesting.CodedUITestMethodInvoker.InvokeMethod(Func`1 function, UITestControl control, Boolean firePlaybackErrorEvent, Boolean logAsAction)
at Microsoft.VisualStudio.TestTools.UITesting.BrowserWindow.Launch(Uri uri)
From where to download selenium-dotnet-strongnamed-2.45.0.zip? The link http://docs.seleniumhq.org/download/ has only selenium-dotnet-2.45.0.zip which throwing error like "System.IO.FileLoadException: A strongly-named assembly is required...."
We have a coded ui test that can be played in IE with out problems. Now we want to play it in Chrome as well.
Cross browser test execution is set up and test can be executed in Chrome. Although as soon as any action on a frame has to be done (e.g. clicking on a hyperlink located inside the frame) test is failing with an error message:
An exception of type 'OpenQA.Selenium.StaleElementReferenceException' occurred in WebDriver.dll but was not handled in user code
Additional information: stale element reference: element is not attached to the page document
(Session info: chrome=41.0.2272.118)
(Driver info: chromedriver=2.8.241075,platform=Windows NT 6.1 SP1 x86_64)
It looks like cross browser execution does not support accessing frames from the test. Is it a known issue? Is there a work around for this?
Thank you for your reply. I have tried one more time from scratch. Recorded a simple test in IE and executed it in Chrome. No problems with accessing frames were encountered.
Still not clear what exactly has helped :)
I have create a simple test to browse on simple google URL. I have executed this code in debug mode, run mode and also through command prompt with MStest.exe . In all it working fine.
Now when I try to build and execute this code through teamcity where test agent is configure on test VM i m getting error as follow:
at Microsoft.VisualStudio.TestTools.UITesting.UITestControl.GetPropertyValuePrivate(String propertyName)
at Microsoft.VisualStudio.TestTools.UITesting.UITestControl.GetPropertyPrivate(String propertyName)
at Microsoft.VisualStudio.TestTools.UITesting.UITestControl.GetPropertyOfType[T](String propertyName)
at Microsoft.VisualStudio.TestTools.UITesting.CodedUITestMethodInvoker.InvokeMethod[T](Func`1 function, UITestControl control, Boolean firePlaybackErrorEvent, Boolean logAsAction)
I am not sure why this happening .
Because i have make sure that code is executing properly on Test VM through VSTS IDE but if open the solution build by teamcity its giving same error not sure what happening?
I am trying to use this plugin to start my tests on chrome, in process i encountered several issues:
- The agent process was stopped while the test was running. - this one appear randomly sometimes same test can throw it twice then pass or other way around is there any way to have these tests more stable ?
- StaleElementReferenceException - appears especially in debug mode, when i run my tests not in debug they work fine. Is there any way to get rid of this ? I tried:
For "the agent process was stopped" error it most probably is an exception being thrown on a separate thread. Are you spawning other threads as part of your test run?
As you said, the AlwaysSearch configuration is the way to go to resolve the StaleElementReferenceException.
I am running behat with selenium browser controller.
With headless browser it is working.But with selenium is giving the following error:
Failed to connect to localhost port 4444:Connection refused
Firefox version :37.0.1
Selenium server: 2.45.0
Thanks in advance.
I use MTM 2013, and I have a problem with Assert in cross browser playback.
Inner text of assert in IE save without any space, while in chrome or Firefox consider all space in inner text. because of this , all of test in cross browser playback has failed.
could you please help me to solve this issue ?
thanks for you're replay
.Contains does not work too, because this method say: string A contains String B,but string A does not have exactly string B
forexample: A= "a b c d e" , B="ab"
A dose not have B , "a b" is different from "ab"
Values of "InnerText" are not really controlled by CodedUITest. This can vary from browser to browser - depending upon how those browsers handle those controls.
InnerText exists as property in CUIT because IE supports it primarily.
Use "textContent" or "innerHTML" and compare those values between IE and other browsers as they are W3C compliant properties.
Out of the two
2. Control.Text = "Value"
Which is better for entering value in a simple HTML text filed. In most of the case both are working, but i came across few times where Control.Text = "Value" fails with error message like below.
"... threw exception:
Microsoft.VisualStudio.TestTools.UITest.Extension.PlaybackFailureException: Cannot perform 'SetProperty of Text with value "A..." on the control. Additional Details:
Depends on the control.
On the other hand, .Text is programmatic setting of value and it depends on the control. Some controls might be defined in such a way that they do not support "setting" of value.
I get the exception 'stale element reference: element is not attached to the page document
(Session info: chrome=39.0.2171.71)
(Driver info: chromedriver=2.8.241075,platform=Windows NT 6.3 x86_64)'
I feel this is due to the usage of multiple UIMaps. Each time I use a method which is in a different UIMap, I get this exception.
I have tried the following -
1) Adding wait.
2) Browser refresh. Is browser refresh supported on non-IE browsers?
Please suggest a solution for this.
This usually happens when the control cached by the test is stale. Try adding this to the "Control" object that is throwing above error:
This ensures that CodedUITest will always search for the control instead of using the one in cache.
I tried to understand what's going on. And what I saw was that the problem probably it's :
when changed the title to the browser after logging and it seems that he can not access the browser but he find it (its properties was updated the url )
It seems that when he changed the title is not recognizing that it's the same process
Direct access to the browser object of bringing null reference exception
Approach that does not directly - bringing fall above stale element
I have tried the following -
1) Adding wait.
2) Browser refresh.
could you please help me to solve this issue ?
I am using the below XML, and Test attribute. When I run the test using IDE, I am seeing two results in the test explorer window. When I create an Order test I am seeing the result count is doubled. My test data is such that only one data per test case will come from XML.
<?xml version="1.0" encoding="utf-8" ?>
[DataSource("Microsoft.VisualStudio.TestTools.DataSource.XML", "|DataDirectory|\\TestData01.xml", "acc1", DataAccessMethod.Sequential),
In the code, I am using the below to get the login id for the given test case: TestContext.DataRow["loginID"]
This is how the result output in the test explorer window:
Test Name: CodedUITestMethod_XML
Test FullName: DataDrivenTestingSample.CodedUITest1.CodedUITestMethod_XML
Test Source: d:\MyMedia\eLearning\DotNet\CodeExamples\DataDrivenTestingSample\DataDrivenTestingSample\CodedUITest1.cs : line 28
Test Outcome: Passed
Test Duration: 0:00:17.7147012
Result1 Name: CodedUITestMethod_XML
Result1 Outcome: Passed
Result1 Duration: 0:00:08.9318932
Result2 Name: CodedUITestMethod_XML (Data Row 0)
Result2 Outcome: Passed
Result2 Duration: 0:00:08.782808
This is by design. First Row shows the overall status of the Ordered tests. if there is more than one test in the Ordered test list, then the first entry shows the overall information of all the tests.
From second entry onwards, it shows the data of each individual tests.