Rule Designer API

ilog.rules.dvs.rbtesting
Class IlrRBTScenarioReport

java.lang.Object
  extended by ilog.rules.dvs.rbtesting.IlrRBTScenarioReport

public class IlrRBTScenarioReport
extends Object

Represents the out parameter for the ruleset being tested. Use this class to write failure instructions inside the rules being tested.

Since:
7.0

Constructor Summary
IlrRBTScenarioReport(String executionId, String scenarioName)
          Creates a new IlrRBTScenarioReport instance.
 
Method Summary
 void failOrSkip(String testName, String messageKey, Object[] messageParameters, String messageLocale, boolean fail)
          Adds a test failure or a test skipped report.
 String getExecutionId()
          Returns the execution ID.
 String getScenarioName()
          Returns the name of the scenario.
 List<IlrTestResult> getTestResults()
          Returns the results for the tests run in this scenario.
 void succeed(String testName, String messageKey, Object[] messageParameters, String messageLocale)
          Adds a test success report.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

IlrRBTScenarioReport

public IlrRBTScenarioReport(String executionId,
                            String scenarioName)
Creates a new IlrRBTScenarioReport instance.

Parameters:
executionId - The execution ID.
scenarioName - The name of the scenario.
Method Detail

getExecutionId

public String getExecutionId()
Returns the execution ID.

Returns:
The execution ID.

getScenarioName

public String getScenarioName()
Returns the name of the scenario.

Returns:
The scenario name.

failOrSkip

public void failOrSkip(String testName,
                       String messageKey,
                       Object[] messageParameters,
                       String messageLocale,
                       boolean fail)
Adds a test failure or a test skipped report.

Parameters:
testName - The name of the test.
messageKey - The message key in the messages bundle.
messageParameters - The message parameters.
messageLocale - The locale for the message in the following format: [language][_COUNTRY[_variant]]. Tokens between the brackets [] are optional.
fail - Set to true if this is a failure report. Set to false for a skip report.

succeed

public void succeed(String testName,
                    String messageKey,
                    Object[] messageParameters,
                    String messageLocale)
Adds a test success report.

Parameters:
testName - The name of the test.
messageKey - The message key in the messages bundle.
messageParameters - The message parameters.
messageLocale - The locale for the message in the following format: [language][_COUNTRY[_variant]]. Tokens between the brackets [] are optional.

getTestResults

public List<IlrTestResult> getTestResults()
Returns the results for the tests run in this scenario.

Returns:
The results for the tests run in this scenario.

Rule Designer API

© Copyright IBM Corp. 1987, 2013