Quick Start Guide

This is a quick guide to getting up and running with the appian-locust library. You will need Python 3.7+ installed on your machine before proceeding.

Setup

  1. Install appian-locust using pip, for more comprehensive projects we recommend using pipenv.

pip install appian-locust

2. Configure your test to point at the Appian instance you will be using. You can use example file provided in this repository example_config.json:

  • Set host_address to the address of your Appian instance.

  • In auth, specify the username and password of the user account to use.

{
    "host_address": "site-name.appiancloud.com",
    "auth": [
        "user.name",
        "password"
    ]
}
  1. Run the sample test example_locustfile.py.

locust -f example_locustfile.py -u 1 -t 60 --headless

If everything is set up correctly, you should start to see output from the load test reporting results. This should run for 60 seconds and end with a summary report of the results.

  • For more examples of different site interactions, see the example_*.py files included in this repository.

  • For more in-depth information about the test library, see the rest of this documentation.

Troubleshooting

  • “Failed to establish a new connection: [Errno 8] nodename nor servname provided, or not known”

  • “Login unsuccessful, no multipart cookie found…make sure credentials are correct”

    • check that auth specifies a valid username and password combination for the site you’re testing on in example_config.json.

  • “General request and response debugging”

    • Add self.appian.interactor.record_mode = True to your AppianTaskSet subclass. Files will be placed in /record_responses where the runner is executed.