Skip to main content

Test Amazon Lex bots easily by defining business requirements through conversations.

Project description

amazon_lex_bot_test

https://img.shields.io/pypi/v/amazon_lex_bot_test.svg https://img.shields.io/travis/schadem/amazon_lex_bot_test.svg Documentation Status

Test Amazon Lex bots easily by defining business requirements through conversations:

lex-bot-test --example BookTrip

lex-bot-test --test-file <your-test-file> --alias test --region us-west-2 --verbose

Sample Test Definitions:

This should give you an idea how to define your test cases. Essentially you can test the response attributes and use Python patterns in the test condition. Not an examples from the samples as they don’t have session attributes.

name: test-lex-bot
description: Regression tests for the Amazon Lex bot
botName: your-bot-name
botAlias: test
waitBetweenRequestsMillis: 0
sequences:
- name: book a car with all defaults
  description: book a car with all defaults
  sequence:
  - utterance: <s>"book</s> <s>a</s> <s>car</s> <s>with</s> <s>all</s> <s>my</s> <s>defaults"</s>
    postConditions:
      message:
      - <s>"Ok,</s> <s>Pickup</s> <s>of</s> <s>economy</s> <s>class</s> <s>car</s> <s>tomorrow</s> <s>and</s> <s>drop</s> <s>off</s> <s>in</s> <s>2</s> <s>days</s> <s>in</s> <s>new</s> <s>york?"</s>
  - utterance: <s>"yes"</s>
    postConditions:
      dialogState: ReadyForFulfillment
      slots:
        CarType: economy
        DriverAge: <s>"38"</s>
        PickUpCity: new york
        PickUpDate: <s>".*"</s>
        ReturnDate: <s>".*"</s>
      sessionAttributes:
      - name: cart
        pattern: <s>".*total:</s> <s>$33.35.*"</s>

Features

  • TODO

Credits

This package was created with Cookiecutter and the audreyr/cookiecutter-pypackage project template.

History

0.1.0 (2018-12-12)

  • First release on PyPI.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

amazon_lex_bot_test-0.1.0.tar.gz (12.4 kB view hashes)

Uploaded source

Built Distribution

amazon_lex_bot_test-0.1.0-py2.py3-none-any.whl (6.8 kB view hashes)

Uploaded py2 py3

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page