BRE Policy Unit Testing in BizTalk 2006

BizTalk Rules Composer Helps us creating a Business Rule. A set of Business Rules is called a Policy. A Policy is given a version.

A Rule can be composed from a Vocublary which may contain a Database Table/Field/Row or .NET Class or XML Schema.

The Testing of Database or XML Schema based policies are quite simple. For a Database based policy, one has to provide the connection information and rest is taken care of by the Rule Engine internally. For a XML based policy, one has to provide an instance of the policy i.e. an XML Message.

The tricky part is Testing a .NET Class based policy. It requires you to provide a .NET Class which must implemement IFactCreator or IFactRetriver interface. This is a tedius process for testers. To fasten your testing, you can create your own .NET program which can take a XML Message and Deserialize it to your class and pass that class to your RuleEngine.

I ‘ll be providing code sample in my next Blog.

Thoughts on Life, Events and Current Happenings

Share this:

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.