Typical usage

The application under test is likely to be launched by a shell script or a batch file. In order to integrate Frankenstein, you'll need to locate the line in the script that launches the application under test. This will typically look like this

java ... com.your.package.Application

You'll need to change the line so that it looks like this:

java ... com.thoughtworks.frankenstein.application.PipingMain com.your.package.Application


The following jar files will need to be added to the classpath of the application under test:

Customization

If you're extending Frankenstein, you'll need to write your own main class.

    import com.thoughtworks.frankenstein.application.FrankensteinIntegration;
    
    /**
     * Launches the application under test via Frankenstein.
     */
    public class FrankensteinLauncher {
        public static void main(String[] args) {
             FrankensteinIntegration integration = new FrankensteinIntegration(YouMainClass.class);
             integration.registerEvent(YourCustomEvent.class);
             integration.registerRecorder(YourCustomRecorder.class);
             integration.start(args);
         }
    }

The application can then be launched by changing the appropriate line of the application's script to look like this:

java ... com.your.package.FrankensteinLauncher ...