This is an example script to demonstrate how one can regression test an Amazon Lex bot. It relies on the AWS SDK and the Amazon Lex Runtime Service API.
The user must have IAM permissions to invoke the API functions (e.g., AmazonLexReadOnly
).
# git clone ...
# npm install
$ node testlexbot.js <TestConfigFile>
# examples:
# node testlexbot.js test/CoffeeBot-main.json
# node testlexbot.js test/CoffeeBot-main.json 2>&1 > results.txt
# node testlexbot.js test/CoffeeBot-main.json 2>&1 > results.txt && ./bin/summarizeResults.sh results.txt
This sample code is made available under the MIT-0 license. See the LICENSE file.