Skip to main content
Skip table of contents

XSLT Transformation

Automation Object XSLT Transformation is used to store XSLT transformation in Int4 Suite as test cases. XSLT Transformation test case can be referred by other Automation Objects or Virtualization Objects. XSLT Transformation test case can store 3 payload types:

  1. XSLT Transformation - contains the transformation that can be referred by other objects

  2. Test Input for XSLT - input for testing XSLT Transformation

  3. Test Output for XSLT - output for testing XSLT Transformation

XSLT Transformation can be Executed in APITester Cockpit. During execution Test Input for XSLT is transform by the XSLT Transformation and the result is checked against Test Output for XSLT. Payload Validation can be applied.

Variables

Variables are the container for values that can be used during testing. Each variable contains two values, the one that is calculated based on the reference message/document and the one that is calculated ad-hoc during test case execution.

There are various scenarios where variable processing can be beneficial:

  • Updating document/message content before test execution

  • Capturing data from document/message content after execution

  • Matching documents based on variable content

  • Passing data between test cases

For more details on Variables and their processing, read here: Variables & Variable processing

image-20250418-083747.png

Create button allows variable creation.

Parameter name

Description

Example

Name

Variable technical name

VARIABLE_1

Description

Free text for variable description

Variable One

Type

Type of variable processing

Read & Replace

Find message

Custom

Scope

Variable scope

  • Test case - variable is processed for every test execution

  • Test run - variable is processed only once within a test run

Test Case

Private

Specifies that the variable is not accessible to child test cases

Local Scripts

Local Scripts enable you to define custom scripts that are available within the context of the current Automation Object.

These scripts can be utilized in the following areas:

  • Variable Processing

  • Payload Processing

  • Custom Validations

Please consult the Int4 Aster Documentation for details on the scripting language.

image-20250418-091020.png

Payload Validations

Output payloads after processing by integration platform are validated against previously stored references.

The basic test execution in Int4 Suite will compare the messages (reference and current execution) and report any differences as errors, causing the test to fail. While this may be acceptable for some migration scenarios, not all message differences are errors; some discrepancies are even expected.

This configuration enables adding rules with exceptions that will allow for differences like document numbers, current time and date and others.

Parameter name

Description

Example

Description

Free text for the exception rule

Field1

Expression Type

Expression type. Available options:

  • unspecified

  • XPath

  • Flat expression

This field is optional for all interfaces where there is a single type of output. However, for interfaces that output might be both XML and flat file, it is mandatory to specify the expression type, then it would be only apply to specific file format (XML/JSON or flat file)

XPath

Expression

Path pointing to the field/node where the exception should be applied.

Available syntaxes: XPath, JSONPath, Int4 Flat File Syntax or REGEX

JSONPath and XPath are well-known and popular standards for structured data manipulation. You can find a lot of references and educational material on-line. Worth noting are the testing tools that allow You to experiment with XPath or JSONPath definitions. See here:

Please note that Int4 does not maintain these tools and can’t guarantee for their accuracy.

//ORDER/DATE/text()  (XPATH expression) or START_TAG(BGM+220+)&&END_TAG(+)&& (Flat file expression) or
$.order.date (JSONPath expression) or
REGEX(BGM\+220\+(.*)\+) (REGEX expression)

Rule

Says how the difference should be marked

  • Warning
    Marks the compared fields with yellow color as a "warning".

  • Warning when different based on variable replacement
    In case compared values are different Int4 Suite compares them with specified variable. If reference/current value pair from comparison matches variable values result is marked as "warning".

    Variable name used for checking the values has to be specified in the Processing Parameter column.

  • Warning when different based on value mapping object
    In case compared values are different Int4 Suite compares them with specified values in the Mapping Object. If reference/current value pair from comparison matches mapping values result is marked as "warning".

    Mapping Object name used for checking the values has to be specified in the Processing Parameter column.

  • Ignore
    Even if it is different in the content, it is not highlighted.

  • Change Request
    The difference will be highlighted green in the test report.

Change Request rule are active only when Test Case is run within Test Run type: Change Request Test

 

Parameter

Additional parameter for rules

 

Custom Validations

Custom Validations offer enhanced flexibility for evaluating test case results by allowing the implementation of custom logic using ASTER Scripts.

image-20250418-090503.png

Within the script, you can access test execution data using built-in Int4 Suite functions such as:

  • GET_TC_VAR – to retrieve test case variables

  • GET_VALIDATION_PAYLOADS – to access payloads used during validation

For the test case to be marked as successful, the script must return a _TRUE_ value.

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.