Summary: BVT_TestDataContracts is a service which validates the data contracts for one or even all Microsoft Robotics Studio services.
Included in the Microsoft Robotics Studio 1.5 is a testing tool which looks at every data contract in the bin directory and validates it for proper cloning, binary and xml serialization. Make sure you have built your own services, then run the following from an MSRS command prompt:
dsshost -p:50000 -m:"Test\dss\bvt\bvt_testDataContracts.manifest.xml"
After running this service, you will need to wait a few minutes for it to run, then you will find the following links of interest:
http://localhost:50000/testaggregator
http://localhost:50000/testdatacontracts
Also, after this runs the first time, you will see a file here:
…\test\dss\bvt\BVT_TestDataContracts.config.xml
You can expand
<DllSearchRegex> with regular expressions like this, and only those matches will be tested the next time you run the service. You can use this to test only your own services. For example, you can list individual dll’s, or you can do regex pattern matching
(ex: ‘robo.*’ where ‘.’ matches any character, and ‘*’ is zero or more of the preceding)
[<DllSearchRegex>]
[<string>MyService.proxy.dll</string>]
<string>robo.* </string>
[</DllSearchRegex>]
Keep in mind, there can be false positives. In other words, there are cases where the contract can’t be tested, or other special cases such as simulation entities, where one or more of the tests fail.
However, when a data contract does pass, it is essentially verified to work both locally and in a distributed environment, over http, and using binary serialization.
For those of you planning to share or publish your services, I think you may find this new tool very useful.