Testing Rules


Overview

Tasks

Included with

Tivoli Change Management administration

Overview

Testing rules

Although you can create a rule in either live or test mode, it is a good idea to create rules in test mode and verify them before making them live. After you save a rule, you can test it from the Testing tab of the Rule dialog box.

Rules in test mode are never fired against changes, so the actions associated with them never take place. In test mode, rules are applied against the data you supply and return either a true or false result.

There are two methods you can use to test a rule:

  • Supplying sample values
    You supply the values to use for testing the rule.
  • Using values from actual changes
    You load data from an actual change record.

In general, you should create a new rule in a test mode, test it to verify that the expected results are achieved, then move the rule to a live mode.


Tasks

Testing rules using sample data

You can type sample data to use in each field when you test a rule.

To test a rule using sample data:

  1. From the Rule dialog box, choose the Testing tab.
    Result: The Testing tab appears.
  2. Under Test Values, select a field for which you want to supply sample data.
  3. In the box below the Values column, type a sample value for the selected database field.
  4. Choose Replace to add the value to the Values column of table.
  5. Continue selecting fields and typing sample values until the test data is complete. You should have one value assigned to each field.
  6. Choose Test.
    Result: The following occur:
    • The rule is evaluated using the sample values.
    • The result of the test appears in the Results list.
    • The result is one of the following messages:
      The evaluation is FALSE
      or
      The evaluation is TRUE

Testing rules using actual changes

Many rules are created in an effort to eliminate or reduce bypassed procedures and problems that were experienced in previous changes. Therefore, it is often more logical to test new rules using data from previous changes.

When you select a change, the data from that change record is added to Test Values list to use for test purposes.

To test a rule using data from an actual change:

  1. From the Rule dialog box, choose the Testing tab.
    Result: The Testing tab appears.
  2. Choose Load.
    Result: The Changes dialog box appears, containing a list of all changes in the system.
  3. From the Changes dialog box, select the change to use for testing.
  4. Choose OK.
    Result: The values from the change are loaded into the Values column.
  5. Choose Test to evaluate the rule with the values from the change.
    Result: The following occur:
    • The result of the test appears in the Results list.
    • The result should be one of the following messages:
      The evaluation is FALSE
      or
      The evaluation is TRUE