Compose Testing Data Visually

Our rule authoring tool (FlexRule Designer) allows you to test all types of rules and decisions visually, and also to simulate their execution. When you want to test a decision (in this example a Decision Table), you need to provide some input data to the decision.

There are five ways to provide data to a decision:

  • Compiled Source
  • Procedural Rule
  • Data Composer
  • JSON Composer
  • Excel Sheet

Prepare Data for Testing Decisions and Business Rules

In this post, I want to introduce to you Data and JSON Composer, which allows you to build data visually for testing and simulating execution.

If you select “Data and JSON Composer” from the provider type and then press its browse button (Button with … text), then you will see the following screen:

Prepare Data for Testing Decisions and Business Rules

This is a data and JSON composer screen that allows you to select your type (assemblies and classes) and gather the data that you need to pass to the decision. Data and JSON Composer also allows you to save the prepared data so that the next time you come to this screen, you do not need to manually prepare your data. Instead, you can open the existing data and manipulate it as needed.

As you can see in the next picture, you can add multiple data to the collection.

Prepare Data for Testing Decisions and Business Rules

When you have assigned an assembly and type to an item in the collection, the “Value” becomes available. You can expand this and start filling properties on the type. This advanced editor allows you to enter hierarchical data and collections for all types.

When you have finished entering and preparing your data, you can “Save” them for future. Then by pressing “OK”, you will be ready to test your decision and rules.

Last updated March 10th, 2020 at 10:44 am, Published December 9th, 2014 at 10:44 am