This project has moved and is read-only. For the latest updates, please go here.

Any plans for TFS query support?

Jul 15, 2013 at 9:13 PM

I looked through and didn't find anything so was wondering if there was any plans to support queries that will return a list of test cases, so that instead of having to type in the test case task ID, we could just pick one from the list, and also, have navigation arrows to quickly switch back and forth between test cases (for comparison purposes, to quick copy a line for paste, etc.)

Mike Poz
Jul 16, 2013 at 3:39 AM
Hi Mike,

I plan to support it if someone submits a pull request at =)

Jul 18, 2013 at 12:01 AM
So just to be clear, you mean write the code that will retrieve queries and filter them on test cases and items in the test case category?

If so, I have code that will do this. I also threw together a quick dialog to pick a query and run it, returning the results of that query, as well as a quick dialog that will list out the results of that query in "ID: Title" format within a listbox object.

And then you want me to check it into the above github project? I ask because I've never checked code into github before and I want to be sure that's what you mean before I actually do it.

Mike Poz
Jul 18, 2013 at 1:36 PM
Hi Mike,

Thanks for your willingness to help out! You have it basically right, except that I am not looking for loose code or stub implementations -- I mean a complete implementation of the feature in Test Steps Editor.

You can find a guide to getting started with contributing to projects on GitHub here: LINK

(skip down to the section "Fork the Code, change it, then do a pull request")

Basically, you'll fork the repository, make your changes and commit them to your fork, and then submit a pull request to my original repository with your changes.

Jul 18, 2013 at 6:21 PM
Excellent thanks, I'll try to get it uploaded by Saturday after giving it a good workout today and tomorrow here at work.
Jul 19, 2013 at 5:21 AM
Edited Jul 19, 2013 at 5:24 AM
I did some poking around on the internet and that along with the link you sent me got me up and running, and so I just did as you asked. Here's the description with the fork and pull request:

Added support to retrieve personal and team TFS queries and filter them to make queries that contain "Test case" and "Test Case Category" options.

To support this I added a Select Query button that opens a dialog that displays the available queries in one of two formats, a tree view (similar to what TFS offers) and a flat list. The user can switch between the two by selecting a radio button.

Once a query is selected, it's executed and a new window opens that lists the test cases from the query. Clicking on a test case entry in the window will cause the Test Steps Editor to automatically load the test cases.

Finally, I added a "Refresh" button that will get the test case ID of the currently selected test case in the editor, close the tab and re-retrieve the test case steps from the server.

Feel free to modify as you see fit, I and another tester where I work used it and definitely makes using the tool easier, hope you find the changes acceptable. Two things to note, if the query returns a large results list, it may take some time before the test case selector window appears, and also you have the test steps retrieval executing on a background thread, which means that when you click on a test case in the list view, you need to wait for the main editor window to complete the retrieve before you click on another.

Jul 19, 2013 at 1:58 PM
Hi Mike - thanks for contributing! For anyone else interested in helping out, the work is going on here: