JavaScript for .Net Specification Framework (JSNSpec)

Do Test-Driven Development
on in-line ASP .NET code
Write .NET code in a dynamically
typed language
Use a simple testing framework
you customize for your team
Speed up development by
avoiding the compiling process
Use the same framwork in the browser,
Make one of these
Quote Rotators
for your site.

Download JSNSpec 1.1 Here (new 11/26/2010)

How To Install JSNSpec:


  1. Using Visual Web Developer or Visual Studio
  2. Start up Test.aspx by right-clicking on the file and choosing to view it in your browser.
  3. Use ServerSpecs.js to write your specifications.
  4. Use ServerCode.js to write your code.


  1. Start up Test.htm file and choosing to view it in your browser.
  2. Use ClientSpecs.js to write your specifications.
  3. Use ClientCode.js to write your code.

This is a very simple specification framework and you can use it to develop your own framework. This allows you to create a framework that fits your team's specific needs.

What was new in the JSNSpec 1.0 Release

  1. Use specification language rather than testing language like JSNUnit used to have.
  2. JSNSpec specifies itself and can test itself.
  3. Unlike JSNUnit, JSNSpec can use beforeEachExample and afterEachExample methods that can be shared for a group of specifications.
  4. JSNSpec now runs within Managed JScript on Silverlight.
  5. Unlike JSNUnit, JSNSpec can tally tests that take place after the runner's page load allowing you to perform post-back tests. Follow the pattern at the end of the JSNSpecSpec.
  6. Unlike JSNUnit, JSNSpec cannot provide an XML output yet. It shouldn't be that hard to add in a future release, however.

What's new in the JSNSpec 1.1 Release

  1. I changed the format for the "it" function so that it self registers examples. This allows a more flexible closure situation that allows you to use helper methods between your specs.
  2. The new form uses less indentation which is easier to read.
  3. I removed the Silverlight stuff since Silverlight has decided to not support JavaScript at this time.

For More Information

JSNSpec is a major upgrade to JSNUnit which is still available. There are other specification and testing tools available at this site as well.

Previous Versions:

Download JSNSpec 1.0 Here

If you have any questions or comments about this please visit my site at

This is a free download at this time and is subject to the ValleyHighlands Free License