Examples

Exactor comes bundled with four example applications to demonstrate its use.

Running the examples

All of the examples are located in the docs\examples directory of the Exactor distribution.

To run the web example, which only use commands from the framework, simply change to the directory containing the example and invoke the Exactor batch file wrapper, e.g.


    C:\>cd %EXACTOR_HOME%\docs\examples\web
    C:\>exactor at
    

If the scritps run successfully you should see the following output;


    ExecutionSet started
        started: google-search.act
                OK: SetBaseUrl
                OK: BeginAt
                OK: CheckTitleEquals
                OK: CheckLinkPresentWithText
                OK: SetFormElement
                OK: Submit
                OK: CheckTitleEquals
        ended: google-search.act

    Scripts run: 1
    Failures: 0
    Errors: 0
    

To run the simple, composite and swt examples, which define their own commands and code, Exactor must be invoked with the -lib option to tell the framework where to find the appropriate commands and classes.

For the simple example this would be as shown below;


    C:\>cd %EXACTOR_HOME%\docs\examples\simple
    C:\>exactor -lib classes at
    

If the scripts run successfully you should see the following output;


    ExecutionSet started
        started: calculator.act
            OK: StartCalculator
            OK: CheckResultEquals
            OK: Add
            OK: CheckResultEquals
            OK: Subtract
            OK: CheckResultEquals
            OK: Subtract
            OK: CheckResultEquals
        ended: calculator.act

    Scripts run: 1
    Failures: 0
    Errors: 0