Visual Studio test adapter for NodeUnit

(4) Review
Visual Studio
2013, 2012
Download (412)
E-mail Twitter del.icio.us Digg Facebook
Add to favorites
Reviews (4)
Q and A (2)
Sign in to write a review
Sort by:

by Devcol | January 03 2014

It's great being able to run nodeunit tests within Visual Studio 2013!

It was not so straight forward for me to run existing tests within a nodejs solution.

I encountered the following problems:

* Not all solution tests would get recognised.
** '*.test.js' files within the node_module
would cause an exception. I deleted these files to workaround the issue.
** Use Visual Studio 2013 to format your JavaScript file.

by tallsup | December 11 2013

Updated version works great! Awesome work.

by MDeveloper90 | December 10 2013

I installed it, i have node.js and nodeunit installed correctly, and the text explorer didn't run / find any tests.

Joseph Gordon December 10 2013
| Edit |

A few questions:
1) Are your nodeunit tests contained somewhere (anywhere) in your solution?
2) Do your nodeunit test files have the extension ".test.js"?

by A-Salah | December 10 2013

It lacks many features, I installed the extension and didn't know how to get it running.

There is no project type for it.

Joseph Gordon December 11 2013
| Edit |

I added a new NodeUnit project type (under Javascript). This adds a dependency on NodeJs tools for Visual Studio. Give it a try and see if it's easier now.


Sign in to start a discussion

  • compatibility with newest version of node.js tools 1.0 beta
    3 Posts | Last post April 12, 2014
    • Hi Kevin. Great plugin, I have this working fine on my VS2012 Update 4 install in the office using an older version of the node.js tools.
      I've just set up my home development environment - VS2013 Update2 plus node.js 1.0 Beta (released yesterday) and I'm not able to install the vsNodeTest plugin.
      I'm getting an error/warning that Node.js Tools references must be present before installation can continue.
      I've tried this via the extensions and updates option within VS and also a direct download/install. 
      Same error both times.
      Is there a chance the details of the Node.JS Tools reference has changed and needs updating?
    • (Sorry, I meant Joseph) - I had a great friend Kevin Gordon who also did dev work! - it's early here :)
    • Quick update. I've downgraded to the VS NodeJS alpha tools and this now installs fine.
      looks like something in the beta manifest/signature has changed breaking dependencies
  • Promissing but not working
    3 Posts | Last post December 17, 2013
    • Hi I really need to make this plugin work. I have met all the requirements:
      * node.js is installed
      * Node tools for Visual Studio is installed
      * I can see and use your "Blank NodeUnit Test Application" project template
      * NodeUnit is downloaded locally in the project's node_modules
      * I see the NodeUnitTest.test.js file in the project
      But nothing shows up in the Test Explorer even after I build the solution
      When I open the project in VS I get the following error in the output window:
      ------ Discover test started ------
      Ignoring the specified duplicate source '[...]\NodeUnitTest1\node_modules\nodeunit\node_modules\tap\coverage-example\test\bar.test.js'.
      Ignoring the specified duplicate source '[...]\NodeUnitTest1\node_modules\nodeunit\node_modules\tap\coverage-example\test\baz.test.js'.
      Ignoring the specified duplicate source '[...]\NodeUnitTest1\node_modules\nodeunit\node_modules\tap\coverage-example\test\foo.test.js'.
      >>> DiscoverTests
      An exception occurred while test discoverer 'NodeUnitTestDiscoverer' was loading tests. Exception: Method not found: 'Microsoft.VisualStudio.TestPlatform.ObjectModel.TraitCollection Microsoft.VisualStudio.TestPlatform.ObjectModel.TestObject.get_Traits()'.
      ========== Discover test finished: 0 found (0:00:50.6931521) ==========
      Please help
    • It turns out Test Explorer Traits were added to Visual Studio 2012 in Upddate 1 and my VS installation didn't have any updates. I updated it with the latest (Update 4) and it's working fine now.
      Maybe you should add Update 1 to the requirements just to be sure
    • Great find!  I didn't realize traits were added in Update 1.