foothaa.blogg.se

Visual studio code debug mocha tests
Visual studio code debug mocha tests





What follows is a summary of steps required to setup the desired debugging experience. Having never debugged Mocha unit tests in VS Code, I was reluctantly venturing into uncharted territory. Unfortunately, one of the pre-existing tests was failing on Windows with the latest version of Node (v4.0+) and, I wanted to dig deeper to understand the root cause. While working on a recent GitHub pull request for OmniSharp’s ASP.NET 5 Yeoman generator, I needed to test my changes prior to submitting. Thankfully, VS Code provides first-class Node.js debugging, which makes this type of development experience virtually pain-free. If you’re anything like me, Mocha has become your framework of choice, and Visual Studio Code is your JavaScript editor of choice. To support that testing need, there are several popular unit testing frameworks available, including QUnit, Jasmine, and Mocha. It isn’t always the case in the real world, but the two should move in lockstep. As your JavaScript code base grows and evolves, the need for a solid unit testing story becomes paramount.







Visual studio code debug mocha tests