Skip to main content

Posts

Showing posts with the label VS

Live Unit Testing in Visual Studio 2017

Let’s have a look at one of the coolest feature of Visual studio 2017. If you will see below snapshot, there are many new icons here.  These icons are part of cool new feature called Live unit testing in Visual Studio 2017 Enterprise. Live Unit Testing continuously runs and displays unit test result and code coverage inside editor itself. It automatically finds and runs impacted tests for every line of code. In above diagram, Red cross indicates failed test case, Green tick indicates passed test case and Blue minus indicates the code that have no test coverage at all. Let’s start by looking at failing test case. You can quickly navigate to failing test case by clicking on tooltip as shown below:  And below is my test case: At this point, I’m not really sure why this is failing. So, I’ll go ahead and debug this test We can see here that above particular code has thrown a null referen