Run a Transact Function Unit Test

   Journey Manager (JM) The transaction engine for the platform.  |    Form Builder Platform Developer |  17.10 This feature was introduced in 17.10.

Manager provides the convenient way to test a Transact function by executing a Unit testis a software development life cycle (SDLC) component in which a comprehensive testing procedure is individually applied to the smallest parts of a software program for fitness or desired operation. Unit Testing is a software testing method by which individual units of source code are tested to determine whether they are fit for use. For more information, see http://docs.groovy-lang.org/next/html/documentation/core-testing-guide.html. suite, which you must configure for each Transact function.

You can run a Unit test from the list of Transact functions or from the Transact function Unit Test tab.

To run a Unit test from the list of Transact functions:

  1. Select Services > Transact Functions.
  2. Locate a Transact function and click Run Unit Test.
  3. Check the test result displayed at the top of the page. The successful test is shown below.
  4. If the test has an error, as in the example below, re-run it from the Unit Test tab, see below.

To run a unit test from the Unit Test tab:

  1. Select Services > Transact Functions.
  2. Locate a Transact function and click Edit.
  3. Select the Unit Test tab and click Run Test.
  4. Review the test results or error messages. If there are errors, correct the Transact function Groovy script or Unit test Groovy script and re-run the Unit test to see if it works. The successful test message is shown below.
  5. Check the event log to see the script's execution output.

Next, learn how to configure Unit test parameters.