# Running unit tests while debug session is running in Workbench

Is it possible to run unit test while a debug session is already open in Wolfram Workbench 2.0?

A typical use case follows: I have a debug in Workbench session open.

I evaluate some cells in a sample Notebook. Find some bugs, fix them and write the unit test. Now I would like to run the unit tests.

But Workbench says

If I terminate the Mathematica session, than the kernel state is lost and I have to re-evaluate all the notebook cells.

-
The workbench is based on an older version of the MUnit package which was available as a standalone Mathematica package before there was the workbench and which you might be able to use in an extra session as Akater suggested for his package. You can still find it deep in the directory tree of the workbench/eclipse installation (put a Print[\$Path] in a test and run it). I have never checked if that MUnit package still works without the workbench but it would be the first place to look at. Maybe you'll find documentation for the older package somewhere to start off... –  Albert Retey May 17 '14 at 8:41

Warning: I'm not sure if Workbench uses the same .mt format. It's certainly similar but I'd appreciate comments on that. (An example of .mt file is included in the package. It's not in repository directly, however, — it gets generated by symbol QuickExampleInstall defined in the package)
By means of properly managed CellTags in notebooks, it is possible to run tests associated with specific notebook just by executing test symbol anywhere in it. This functionality, however, is not present in the package I link to, but it's not difficult to add. It may appear there in future but I happen to be losing interest in unit testing, so it probably depends on feedback.