coded-ui-tests

How to create a deploy package for "CodedUI Test" recorded in Visual Studio 2010 beta

A few test scenarios have been recorded using CODEDUI Test template for my web application in Visual Studio 2010 beta. These run from within the Visual Studio successfully without any issues. I was looking for instructions to create a deployment package. If you can guide me with this, I would be grateful. [Note please create a tag for...

UID/name labels in silverlight for unit testing

I am having a problem naming listbox items in a silverlight listbox. The listbox is bound to a DTO collection so the items are determined dynamically at run time. The listbox, itself, is easily named with the x:Name tag in the xaml in this way: <Client:OurListBox Grid.Row="3" Grid.Column="0" x:Name="OurListBox" ...

How do I get ItemStatus from a UITestControl?

The UI Automation framework has a base class, AutomationElement, that has a property, ItemStatus, that can be used to store arbitrary strings. I'm trying to get that property from the Visual Studio 2010 Coded UI Tests base class, UITestControl. ...

How to programmatically start a WPF application from a unit test?

Problem VS2010 and TFS2010 support creating so-called Coded UI Tests. All the demos I have found, start with the WPF application already running in the background when the Coded UI Test begins or the EXE is started using the absolute path to it. I, however, would like to start my WPF application under test from the unit test code. That...

Why does Coded UI Test Builder show MSAA for WPF controls instead of UIA

Question When I select a WPF control with the crossline of the Visual Studio 2010 Coded UI Test Builder (screenshots), it shows that the used accessibility technology was MSAA. Why is it not UIA? Additional information I am trying out the new Coded UI Test feature shipped with VS2010 and TFS2010. I know that there are basically two U...

Adding a proof to VS2010 Testing file

As you know, when you run test (on this case coded ui tests) in visual studio or MS Test a .trx file is generated. Anyone knows a way to "add" a file/resource to such file? I want to add a image capture if my assertion fails. Thanks ...

Where can I find the Visual Studio 2010 RTM release notes?

Question Where can I find a list of changes introduced to Visual Studio 2010 Ultimate RTM that were added since Visual Studio 2010 Ultimate RC? In fact, I'm only interested in changes related to MS Test Manager 2010 and Coded UI Tests. Where I have looked so far I have searched the Internet, looked for a readme.txt in the installat...

Do I need Team foundation server in order to use CodedUI?

Hi, I'd like to write some basic tests for our web and Winforms applications. I already own Visual Studio 2010 Ultimate. Do I also need TFS in order to use the new CodedUI tests? Thanks, Adrian ...

Coded UI Test - How to change the exe it runs

I created a Coded UI Test from a Microsoft Test Manager recording. The exe it runs is the one the tester recorded against. I want this to be a test I run with my build. How do I change the exe that the coded UI test uses to be the output of: The TFS Build when a TFS Build is being run The local build when the test is being run on my...

VS 2010 Coded UI Test - Launch Referenced Application

I'm using Visuial Studio's Coded UI Tests to run Automated UI tests on a WPF Application everytime a build runs on my TFS server. The problem I am running into is dynamically launching the executable based on the path where it was just built to, including the configuration(x86, x64). Is there any way to get the path to an executable in ...

How to keep MaskedEdit extenders from breaking CodedUITests? (Visual Studio 2010)

I'm trying to implement coded UI tests, but have run into a problem. Whenever the test runs across a textbox with a masked edit extender on it, it records the mask as part of the input but does not enter that mask when it "types" that input during a playback. Example: mask is "//__" for a date. If I enter 02 02 2010 the textbox correctly...

How to solve timing problems in automated UI tests with C# and Visual Studio?

Question What is the standard approach to solve timing problems in automated UI tests? Concrete example I am using Visual Studio 2010 and Team Foundation Server 2010 to create automated UI tests and want to check whether my application has really stopped running: [TestMethod] public void MyTestMethod() { Assert.IsTrue(!IsMyAppRun...

How to use AutomationProperties.Name?

Question Can anyone please explain (preferrably with a code example) how the AutomationProperties.Name property is used programmatically and declaratively with XAML? Explanation I understand that the Coded UI Builder in Visual Studio 2010, for instance, takes a Window's name as SearchProperty. Since my Window's name changes, I would ...

How to set property only on second column of a ListView?

Introduction I have a ListView and want to format only the second column. The following XAML code does that: <ListView x:Name="listview"> <ListView.View> <GridView> <GridViewColumn Header="Property" DisplayMemberBinding="{Binding Path=Key}" Width="100"/> <!-- <GridViewColumn Header="Value" DisplayMem...

How do I close the browser (IE8) using Watin?

Hello, I am using Watin 2.0 to develop some automated UI tests. I cannot get Watin to close the browser after it has opened it. The Watin.Core.Browser object implements IDisposible but Dispose() does not do the trick. I have also tried using the Close() method. Most recently I have tried wrapping the IE object instantiation in a Using ...

Starting an application with coded UI tests in VS 2010

When I recorded a test with the recorder in Visual Studio 2010 Premium, I noticed that the recorder doesn't generate the code to start the program. Steps to repro: Add a new Coded UI test to a VB .NET testing project Click "OK" to use "Record actions, edit UI map or add assertions" Click the record button to start recording. Press CTR...

Coded UI Test Builder does not appear with setup project in solution

I am using VS 2010, and I was able to create a Coded UI test successfully, once. I am trying to do the same, but the Test Builder Dialog box does not appear anymore. I found the following post: http://social.msdn.microsoft.com/Forums/en/vsautotest/thread/ff495f15-bb42-454d-88af-ae4d3bb4a075 This describes my problem somewhat. I do have...

How to parameterize date value if the eWorld.Ui Date control is used.

In my Coded UI Test script code for date is generated like, // Click '/images/calendar.gif' image Mouse.Click(uIImagescalendargifImage, new Point(9, 6)); // Click '26' link Mouse.Click(uIItem26Hyperlink, new Point(5, 6)); I want to parameterized date. Here it takes x,y co-ordinate. How can I pass val...

MSVS2010 Coded UI Tests no longer work when saving/generating methods

The coded UI test functionality used to work, but now it won't allow any methods to be saved. I keep seeing the following error: "The code could not be generated because the cursor in the source code file is not located within a method. Place the cursor in the method where you want to insert the generated code." I receive this error w...

Can anybody tell me, How should be Folder Structure in Coded UI.

I want to create specific folders stucture for my Coded Ui tests. Please guide me, How it should be? As like QTP Framework. Can we keep specific files to specific folders, if yes then can anybody share format. ...