We always want to find problems early after changes are checked in and built by running continuous tests using Visual Studio Team Services or Team Foundation Server.
This article explain how to set up continuous testing for your builds using TFS 2015/2017.
It is three step configuration process.
Step 1: Set up app deployment for your build
Step 2: Set up test deployment for your build
Step 3: Set up your tests to run with your build
I hope this will help !!!