1
votes

I am using VsTest - testAssemblies task in my release definition to perform integration testing for our app tier code but the release definition fails at the beggining itself, if VsTest - testAssemblies task is used in it.

It gives this error in the summary of the Release definition - "No agent found in pool POCGen-Dev which satisfies the specified demands: Agent.Name -equals CID21 vstest Agent.Version -gtVersion 2.103.0 "

The Release definition works fine if i remove the VsTest - testAssemblies task from it, but when i used\add it in Release definition it fails.

I tried googling but no help!! Can anyone please let me know what should i check or do in this case? enter image description here

Screenshot of Capabilites of Release Agent

enter image description here

1
So, have you set the demands on Run on Agent phase? The error message explicitly point out that the current agent doesn't match the demands. Just try checking your release agent capabilities to verify if the agent have these capabilities : Agent.Name -equals CID21, vstest , Agent.Version -gtVersion 2.103.0 Andy Li-MSFT
I checked the capabilites of the Agent in Agent Queue and the Agent Version for the agent CID21 is 2.122.1 currently, and i think VS test task requires Agent version to be 2.103.0, so how can i update the Agent Version now? In this case i have to downgrade my agent version, is it possible?SRP
-gt means greater than, so that's not the cause. Are you sure you have the vstest capability on your release agent?Andy Li-MSFT
Yes, the capabilities for the VSTest are present for my release agent, previously it were not there so i removed the agent and installed the VS 2017 and updated the VS and then again installed the Agent and after that it started showing me the capabilities for VS test. I have attached the screenshot of the same of all the capabilities at the top for the agent.SRP
A bit strange, have you tried other agents? you can try deploy a new agent then try it again to check if it works.Andy Li-MSFT

1 Answers

0
votes

I was able to resolve the error for the above asked question by performing the following steps-

1.Uninstalled the existing Release Agent from the Machine.

2.Had to install VS 2013 even though i had VS 2017 already installed on my machine.

3.After installing VS 2013, I restarted the machine.

4.I installed the Release Agent on the machine and validated the VStest capabilities under the System Capabilites of the Release Agent.(VSTest_12.0 and VSTest_15.0).

5.Then triggered the Build defintion which triggered the Release definition and it executed successfully all the tasks including Visual Studio Test task. (VsTest - testAssemblies) and dislayed the results in Tests tab of the release definition.

I think the VS test task doesn't work with VS 2017 and is not compatible due to which i had to install VS 2013, you can install VS 2015 as well.

Scrrenshots of Capabilities for Reference.

enter image description here

enter image description here