Extending DevOps Test Integrations and APIs functionality by using custom functions

You can add more calculations and operations to tests by using the HCL DevOps Test Integrations and APIs (Test Integrations and APIs) custom function class. Test Integrations and APIs custom function is a Java class that extends the com.ghc.ghTester.expressions function.

Note: All custom functions can be called from any of the supported scripting languages in Test Integrations and APIs.

The following steps provide an overview of how to develop a function for use in Test Integrations and APIs:

  1. Create a plug-in, which is a Java code wrapper that allows the plug-in to be loaded into Test Integrations and APIs. Using the Eclipse IDE for Java EE is the easiest way to create a plug-in, but you can also create a plug-in from a different IDE.
  2. Develop your function class, which involves creating a Java class and implementing the function behavior. If you have an existing function and want to modify it to work with Test Integrations and APIs, you must convert existing function classes with Eclipse.
  3. Create a function extension to provide Test Integrations and APIs with details about your function, such as its name and the class that implements the function.
  4. Configure and use the function in Test Integrations and APIs, which lets Test Integrations and APIs load your function to be used inside your Test Integrations and APIs project.