GenRocket Runtime Real Time Socket Engine helper classes
The GenRocket runtime comes with a few helper classes that can be used to call the GenRocket Realtime Socket Engine. The helper classes are written in Groovy but are compiled down to a Java binary; they are the following:
-
com.genRocket.tdl.LoaderDTO: A data transfer object used to transfer generated test data.
-
com.genRocket.tdl.ScenarioParams: An object used to pass parameters to the socket.
- com.genRocket.tdl.TestDataLoader: Contains helper classes to connect to the socket.
These helper classes exist in the GenRocket runtime jar. Make sure to download the GenRocket runtime to your local computer. For more information on how to install the GenRocket runtime visit this article for Windows installation or this article for MacOS/Linux installation. Unzip the runtime and pull the genrocket.jar from the lib folder and place in your Grails project lib folder.
LoaderDTO
ScenarioParams
TestDataLoader
Example Test Data Loader
The following code is an example of a Groovy class using the TestDataLoader Design Pattern (TDL) with the GenRocket helper classes to call the GenRocket Real Time Socket Engine to generate user data.