How to run unit tests in TFS (using vNext)

972 Views Asked by At

I have the following project in my Visual Studio 2015 solution. I want to execute jasmine tests as part of our TFS CI build. I can run my tests successfully when I open the SpecRunner.html file although I'm failing to get them to run as part of the TFS build. I've included a screen shot of my TFS build step definition. The build is successful but the tests are not executed.

Please advise, any help greatly appreciated.

Many thanks,

Project and file locations

project and file locations

TFS build step

enter image description here

1

There are 1 best solutions below

13
PatrickLu-MSFT On

First make sure your environment on the build sever is set correct. You could manually run the test on the build server.

To use a NuGet package for the Chutzpah test runner , then you can avoid having to manually unpack the VSIX and get it into source control to deploy it to the build host.

About the detail step and build definition you could take a look at this tutorial: nUnit and Jasmine.JS unit tests in TFS/VSO vNext build

enter image description here