Verifying received data with custom Java™ code
With custom verification points, you can use Java™ code to verify the data received through a connection.
Before you begin
Using Java™ custom code requires knowledge of the Java™ programming language and of the HCL OneTest™ Performance API. See Executing test execution with custom code for more information.
About this task
When you add verification points, the received data is compared with the expected data that is specified in the verification point test element. Custom verification points return a Pass status when the custom class returns a Pass status after performing a verification written in Java™ code.
Procedure
To add a custom verification point to a socket test:
- Open the test editor, right click a socket receive element, and select .
-
Select the verification point, and in the Test Element Details area of
the test editor, click Generate Code.
This action generates a Java™ class that is based on the template of the HCL OneTest™ Performance API for socket custom verification points.
- Edit the Java™ code to define the specific verification action to perform.
- Save and close the Java™ class.