1

I am using TFS and have a Test Plan. All of the tests in the plan are automated. When creating a test plan, a Release must be created with a Visual Studio Test task included. That has worked until now, but there are a few things that we wanted to do along with running the tests. Specifically, we are replacing some tokens in a .runsettings file and then deleting the file after the tests have run.

I wanted to encapsulate all of that functionality in a Task Group since it seems like a common task that we will want to use often. Rather than having to add each task and configure them, a user could add the Task Group, set some parameters, and it just works.

When I try to execute a Test Run, I get this error

Validating environment:The Visual Studio Test task in the environment you selected is not the correct version, or has incorrect settings.

I am assuming that the issue is that I dont have a Visual Studio Test task included in my Release definition, but that is because the Task is included in my Task Group. Is there any way for this to work? I want to run automated tests while the Visual Studio Test task is part of a Task Group.

It looks like someone has requested this functionality on UserVoice, but I was hoping that there was a workaround. https://visualstudio.uservoice.com/forums/330519-visual-studio-team-services/suggestions/33921664--test-run-step-not-detected-in-test-hub-when-in-t

Thanks

bsayegh
  • 990
  • 6
  • 17
  • I don't understand your question. A task group is used within a build or release definition. – Daniel Mann Jun 27 '18 at 18:56
  • @DanielMann If you want to kick off automated tests from the Test Plan screen, your Test Plan has to have a Release definition. The Release executes the Visual Studio Test task. While you can normally run any Task Group as part of a release, a Test Plan release requires the Visual Studio Test task. If that task is part of a Task Group, it isnt recognized and TFS wont even attempt the Test Run. – bsayegh Jun 27 '18 at 19:07

1 Answers1

0

Current task groups for planned automation testing is not supported.

As you could see the user voice in our main forum for product suggestions:

"Test Run" step not detected in Test hub when in Task group

https://visualstudio.uservoice.com/forums/330519-visual-studio-team-services/suggestions/33921664--test-run-step-not-detected-in-test-hub-when-in-t

You could vote up and monitor it. TFS PM and Admin will kindly review your suggestion. Thank you for helping us build a better product.

Unfortunately, there is not any workaround for now. Suggest you exclude the test related in your task group for now.

PatrickLu-MSFT
  • 49,478
  • 5
  • 35
  • 62
  • I have voted for that idea and hope it gets done. There are some features and configurations missing from TFS that kind of boggle my mind. Thanks for the info. – bsayegh Jul 03 '18 at 13:47