none
About agent licensing when compile codedui tests RRS feed

  • Question

  • I use TFS 2017 and for my codedui tests I use run assemblies Task in my build.

    I see in TFS build that, compile and run assemblies needs to be on same pc (agent) since they are in same build, every agent using this build needs enterprise license ?

    Really confused on this issue. I need separate license for every agent then ?

    Lets say I have 5 different agents on different virtual servers, they all need the enterprise license for compiling dlls ?

    Or I just install VS on every agent, it compiles my code and runs but DO NOT need license since agents will not open VS editor write code




    • Edited by rastek Thursday, September 12, 2019 6:37 PM
    Thursday, July 25, 2019 12:36 PM

Answers

  • Hi rastek,

    Welcome to MSDN forum.

    Sorry to disturb you and just want to confirm if this issue is solved or not.

    Actually you don't need to install vs in agent. To compile the code in agent, you download the separate, free build package: Build Tools for VS2017 (Don't need the Enterprise license of VS). See this similar issue.

    And this is a popular way for CI build as far as I know. You can download this free package in your build server, then double-click the vs_buildtool_xxx.exe and make sure you've configured related build workloads and components:

    If you want to build C++ projects, then configure the installation to load the corresponding C++ build Tools. After that, you can use TFS to call msbuild.exe to build C# projects including C# Test Projects.

    And about how to run test project, please check the suggestion in Dylan's answer.

    Best Regards

    Lance


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.



    Friday, August 2, 2019 7:27 AM

All replies

  • Hi rastek,

    Thank you posting here.

    According to your description, did you want to run the Coded UI test with command line in different servers?

    If so, please follow this BLOG to download the vstest tool without VS IDE, then type the below command:

    vstest.console.exe myTestProject.dll

    Please refer more here: https://docs.microsoft.com/en-us/visualstudio/test/vstest-console-options?view=vs-2019

    BTW, if you have other issues about TFS, please redirect to Stack Overflow with TFS tag for better support.

    Any feedback will be expected.

    Best Regards,

    Dylan

    Note: This response contains a reference to a third-party World Wide Web site. Microsoft is providing this information as a convenience to you. 
    Microsoft does not control these sites and has not tested any software or information found on these sites; Therefore, Microsoft cannot make any representations regarding the quality, safety, or suitability of any software or information found there.
    There are inherent dangers in the use of any software found on the Internet, and Microsoft cautions you to make sure that you completely understand the risk before retrieving any software from the Internet


    MSDN Community Support Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com


    Friday, July 26, 2019 2:31 AM
  • Hi rastek,

    Welcome to MSDN forum.

    Sorry to disturb you and just want to confirm if this issue is solved or not.

    Actually you don't need to install vs in agent. To compile the code in agent, you download the separate, free build package: Build Tools for VS2017 (Don't need the Enterprise license of VS). See this similar issue.

    And this is a popular way for CI build as far as I know. You can download this free package in your build server, then double-click the vs_buildtool_xxx.exe and make sure you've configured related build workloads and components:

    If you want to build C++ projects, then configure the installation to load the corresponding C++ build Tools. After that, you can use TFS to call msbuild.exe to build C# projects including C# Test Projects.

    And about how to run test project, please check the suggestion in Dylan's answer.

    Best Regards

    Lance


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.



    Friday, August 2, 2019 7:27 AM
  • Hi rastek,

    If you want to build your application only in the agent, you would better install the Build Tool for 2017 rather than install the VS IDE.

    If your issue still exists ,please feel free to let us know.If the reply is helpful for you to solve the issue, please remember to mark as answer.

    Best Regards,

    Perry


    MSDN Community Support Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com

    Wednesday, August 7, 2019 10:38 AM
  • Dylan the blog you sent show a nuget packages, so don't I need VS installed in oerder to install a nbuget package ?

    I went github page for vstest and downloaded as zip and I see sln files, that means its need VS.

    I can also get clone via git but what I wonder is, there is no just download and use package for agents ?

    Do I need to install some .NET or nuget installer for agents, I am confused.

    • Edited by rastek Thursday, September 12, 2019 6:36 PM
    Thursday, September 12, 2019 6:30 PM
  • Hi Dylan, actualy there is no binary in that blog, just project package for nuget and github.

    I downloaded project as zip from github and open in VS, build vtest console app only (tried to build all solution but dit not succeed) (I still do not know how to get those binaries without build them in VS ??)

    I open binary folder , run cmd and tried to run vtest.console and get this error, can you help ?

    No suitable test runtime provider found for this run.

    anyway I build vstest console and run (I had alread used vtest.console in VSthroough TFS build ) and get error message saying

    No suitable test runtime provider found for this run

    I searched a bit but did not find reasonable solution for this, can you help me ?

    and there are 59 projects in that package, what are they for ? whicih ones I need for codedui tests ?

    I have reead some guides but that platform is for developers, not for testers. its likes a joke. It doesnt tell anywhere how to setup vtest.console for an agent with minimal environment.

    I wonder if I can directly copy-paste and use vtest.console under VS 2017/2019

     
    • Edited by rastek Thursday, September 12, 2019 7:59 PM
    Thursday, September 12, 2019 7:30 PM
  • Hi rastek,

    Thank you for feedback.

    I'm sorry that I didn't provide some details to implement it ,then caused this misunderstanding.

    Then blog I shared shows that how to call vstest.console.exe without VS IDE to run coded ui test. The nuget package is like a zip file, you could unzip it to get vstest tool.

    >>No suitable test runtime provider found for this run

    After my experience, I could reproduce this error on my side. Then I have compare the Testplatform folder which is from nuget package with the one from VS path, I found nuget package lacks some files.

    Solution(Run Test):

    I recommend you could copy the whole TestPlatform folder from other machine which install VS with test tool.

    The Path:

    C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\Extensions\TestPlatform

    Then open cmd tool or developer command prompt for VS, and type below command:

    cd C:\Users\Admin\Pictures\TestPlatform
    vstest.console.exe C:\Users\Admin\Pictures\CodedUITestProject1.dll

    The result shows:

    Hope it could help you.

    Best Regards,

    Dylan


    MSDN Community Support Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com


    Friday, September 13, 2019 4:11 AM