Versions:3.6+
QuerySurge Test Management Tool Connector Setup
The Scheme:
QuerySurge's Test Management Tool Connector works with TFS's Test Agent to enable you to execute QuerySurge tests from TFS, and for results from QuerySurge to flow back to TFS. The following scheme shows the relationships between these components:
Note: the steps in this section can be done with any PC on your corporate network that has Microsoft Visual Studio 2013 and Microsoft Test Manager 2013 installed. Some steps in this section refer to the install directories for the QuerySurge TFS Connector, so please make sure that you have access to a Connector installation.
- In your Connector installation directory, open the open the properties file, which, if you chose the default options while installing QuerySurge, are found in the C:\Program Files\QuerySurge\cli folder
- In the file, insert a line right after # Client API and type the UsernameYouWantToUseFromQuerySurge=PasswordOfUsernameInQuerySurge
- Launch Visual Studio
- Choose File->New->Project
- Choose Unit Test Project, give the project any name you want, and press the OK button
- Right click on the Project and choose Add->Existing Item
- Assuming you installed the QuerySurge Connector in the default location, navigate to C:\Program Files\QuerySurge\cli\samples
- Select all the .cs files and click the Add button
- Open up the cs file and fill out the QuerySurgeInstallationPath, hostname and port values to match the machine that has QuerySurge installed and then save the file
- Open up the cs file and fill out the username, scenarioName and suiteIdList values and then save the file
- Right click on References and choose Add Reference
- Type System and make sure that you see a checkbox next to System
- Type Data and make sure to click the checkbox in the field and press the OK Button
- Choose Build->Build Solution
- In order to test locally to make sure that you set up everything properly, right click on QuerySurgeConnectionBySuiteIdTest and choose the Run Selected Tests option
- Depending on which suite you picked the test will pass or fail (Even one querypair failing will cause the whole test to fail)
- Click on Team Explorer
- Click Create Team Project
- Enter the name of the project and press Next
- Keep the default option and press Next
- Choose Team Foundation Version Control and press Next
- Hit Finish (Please note that it may take a few minutes to create your project)
- Click Close
- Right click on the Project you created and choose Connect
- Click Configure your workspace
- Click Map & Get
- Click on Builds
- Click New Build Definition
- Give the Build definition name
- Click Process
- Change Disabletests to True
- Click Build Defaults
- Type the location you want the output or log results of the test copied to
- Click the Save button
- Click on Solution Explorer
- Right click on the solution and choose Add Solution to Source Control
- Choose Team Foundation Version Control and hit the OK button
- Choose the Team Project Location, type a name for the solution, and hit the OK button
- Right click on the solution and choose Check In
- Type a Comment if you wish and then press the Check In button
- Click Yes
- Click the Home button
- Click Builds
- Right click on the build definition and choose Queue New Build
- Click the Queue button
- Keep hitting the Refresh button until the build completes
- Open Microsoft Test Manager
- Click your project and then the Connect now link
- Click the Add button
- Enter any Plan name you want and then click the Add button
- Click Select plan
- Navigate to Lab Center
- Click New
- Give the Environment a name
- Click Machines
- Enter the appropriate credentials for your Machine
- Click Verification
- Click the Verify button
- Click Finish
- Keep clicking the Refresh button until ready
- Click on Test Settings
- Click New
- Give the settings a name and then Choose Automated
- Click the Next button
- Click on the environment
- Click the Finish button
- Click on Testing Center
- Click on Properties
- Set the Test settings and Test environment and hit the Save button
- Click the Modify link
- Choose the latest build and click the Assign to plan button and hit the Close button
- Click the Save and Close button
- Back in Visual Studio, in Team Explorer, click on Work Items
- Click New Work Item->Test Case
- Enter the test case name and click Associated Automation
- Click the Automated test name button
- Choose your test name and click the OK button
- Click the Save Work Item button
- In Test Manager, click the Add button
- Click the Run button
- Click the test case and the Add test cases button
Running QuerySurge from TFS
Note: The steps in this section can be done with any PC on your corporate network that has Microsoft Test Manager 2013 installed and where the QuerySurge TFS Connector is already installed. The Connector can be installed from the QuerySurge installer.
- Click Test
- Right click and choose Run
- Keep hitting the refresh button until the scenario finishes
- Click on Tests
- Right click and choose View Results to view the results of the test run
- Right click on the Attachment and choose Open
- Click Open and the results will open
Troubleshooting
Note: The steps in this section can be done with any PC on your corporate network that has Microsoft Test Manager 2013 installed and where the QuerySurge TFS Connector is already installed. The Connector can be installed from the QuerySurge installer.
A TEST FAILS WHEN RAN FROM MICROSOFT TEST MANAGER BUT OFFERS NO LOG SHOWING THE FAILED QUERYPAIRS
This may be related to the fact that the agent for Microsoft Test Manager is set to run as a Windows service. To resolve this issue, have the agent locally on the machine where the agent is visible.
Comments
0 comments
Please sign in to leave a comment.