integrating the result of javascript unit test runs, into the Visual Studio build report from TFS


problem: we are running javascript unit tests, via a command line tool, as part of a Microsoft Build run by TFS.

We want to see the results of the javascript unit tests runs, in the main report that shows up in Visual Studio.

solution: code generation

as a *pre* build step, on a unit test project:

1. run the js unit tests (via cmd line tool like jsPhantom)
2. collect the names of tests, and their results (pass/fail), via a script
3. generate C# unit test code, via a script
4. each unit test should be named after a js test, and be coded to pass/fail appropriately
5. each unit test fail message, should tell user to check the *js* unit tests
6. the project will then be built + unit tests run by MS Build

note: for the scripts, a scripting language like Python or Powershell would be suitable

Comments