The actual version is only a proof of concept to study the feasibility and to experiment the idea.
Currently only TSQL and MDX languages are supported.
A brief guide on how to use it:
- Place the queries you want to test into an XML file. Give it .qut extension and use the included XSD schema to verify it.
- Run the QueryUnitPOC.exe application, passing the .qut file that contains that tests you want to run. It will load it and will create a Class Library at runtime using the file ClassTemplate.vt as template. It will also produce the created C# source code.
- If everything goes well, NUnit GUI will pop up.
- Run the tests :-).
Included in the released files you can find the AWTest.qut file which shows a sample unit testing of both MDX and T-SQL queries. It needs the AdventurWorks 2008 samples to work properly.
If after the NUnit GUI pops up you receive an error that tells you that the "nunit.framework.dll" cannot be found, you just have to copy that nunit assembly in your directory or, better, register it into the GAC.