Yesterday I’ve released a refreshed version of QueryUnit Proof-Of-Concept to fix some problems due to localization settings. Now all expected values are managed using the InvariantCulture culture.
Using the InvariantCulture Property
http://msdn.microsoft.com/en-us/library/4c5zdc6a.aspx
I’ve also added the support for “format” element so that from now on you can define how to format the data before the assertion gets evaluated, specifing the preferred format, just using the usual .NET formats:
Formatting Types
http://msdn.microsoft.com/en-us/library/fbxft59x(VS.71).aspx
In this way, for example, if yor query generates the number 1309047.1978 and you’re just interested in the first two decimal numbers, you just have to specify the value “##.00” as a format value:
<CellSetResult ordinal="0" type="Decimal" assertion="AreEqual" value="1309047.1978" format="##.00"/>
or
<CellSetResult ordinal="0" type="Decimal" assertion="AreEqual" value="1309047.20" format="##.00"/>
Happy testing!
UPDATE:
For those who ask: sorry I forgot to put the link to the tool [:)]. Here it is:
http://queryunit.codeplex.com/