-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
adapt digressions, flow_guards, skip_question
- Loading branch information
Showing
15 changed files
with
354 additions
and
0 deletions.
There are no files selected for viewing
28 changes: 28 additions & 0 deletions
28
e2e_tests_with_assertions/passing/digressions/intermittent_flow_switch.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
test_cases: | ||
- test_case: user makes an intermittent flow switch | ||
steps: | ||
- user: I need to transfer some money to John | ||
assertions: | ||
- slot_was_set: | ||
- name: route_session_to_calm | ||
value: True | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_amount_of_money | ||
- user: How much do I have on my account? | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_current_balance | ||
- bot_uttered: | ||
utter_name: utter_flow_continue_interrupted | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_amount_of_money | ||
- user: ah, great, I owe him $500 | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_final_confirmation | ||
- user: "yes" | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_transfer_complete | ||
- bot_uttered: | ||
utter_name: utter_can_do_something_else |
15 changes: 15 additions & 0 deletions
15
e2e_tests_with_assertions/passing/digressions/user_answers_and_also_asks_a_question.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
test_cases: | ||
- test_case: user answers and also asks a question | ||
steps: | ||
- user: I want to send 50$ to Justin | ||
assertions: | ||
- slot_was_set: | ||
- name: route_session_to_calm | ||
value: True | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_final_confirmation | ||
- user: yes, and btw are there any fees associated with the sending? | ||
assertions: | ||
# not able to test the response of enterprise search yet | ||
- bot_uttered: | ||
utter_name: utter_transfer_complete |
21 changes: 21 additions & 0 deletions
21
e2e_tests_with_assertions/passing/digressions/user_asks_for_a_moment_to_think.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
test_cases: | ||
- test_case: user asks for a moment to think | ||
steps: | ||
- user: I want to send money to Yizhi | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_amount_of_money | ||
- user: one moment | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_take_your_time | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_amount_of_money | ||
- user: "100" | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_final_confirmation | ||
- user: "Yes" | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_transfer_complete |
34 changes: 34 additions & 0 deletions
34
e2e_tests_with_assertions/passing/digressions/user_asks_what_info_is.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
test_cases: | ||
- test_case: user asks what requested information is | ||
steps: | ||
# NLUCommandAdapter should start the flow, so "Peter" is not detected as an entity | ||
- user: I want to add Kate to my contacts | ||
assertions: | ||
- slot_was_set: | ||
- name: route_session_to_calm | ||
value: True | ||
- bot_uttered: | ||
utter_name: utter_ask_add_contact_handle | ||
- user: What's a contact handle? | ||
assertions: | ||
# not able to test the response of enterprise search | ||
- bot_uttered: | ||
utter_name: utter_ask_add_contact_handle | ||
- user: Ah okay she sent it to me, it's @KatePurry | ||
assertions: | ||
- slot_was_set: | ||
- name: add_contact_handle | ||
value: "@KatePurry" | ||
- bot_uttered: | ||
utter_name: utter_ask_add_contact_name | ||
- user: Kate | ||
assertions: | ||
- slot_was_set: | ||
- name: add_contact_name | ||
value: "Kate" | ||
- bot_uttered: | ||
utter_name: utter_ask_add_contact_confirmation | ||
- user: "yes" | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_contact_added |
28 changes: 28 additions & 0 deletions
28
e2e_tests_with_assertions/passing/digressions/user_asks_why_information_is_needed.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
test_cases: | ||
- test_case: user asks why information is needed | ||
steps: | ||
- user: I want to verify my account | ||
assertions: | ||
- slot_was_set: | ||
- name: route_session_to_calm | ||
value: True | ||
- bot_uttered: | ||
utter_name: utter_ask_verify_account_email | ||
- user: It's [email protected] | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_ask_based_in_california | ||
- user: Why do you need to know this? | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_california_compliance | ||
- bot_uttered: | ||
utter_name: utter_ask_based_in_california | ||
- user: "No" | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_ask_verify_account_confirmation | ||
- user: "Yes" | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_verify_account_success |
28 changes: 28 additions & 0 deletions
28
e2e_tests_with_assertions/passing/digressions/user_refuses_to_provide_information.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
test_cases: | ||
- test_case: user refuses to provide information | ||
steps: | ||
- user: I want to verify my account | ||
assertions: | ||
- slot_was_set: | ||
- name: route_session_to_calm | ||
value: True | ||
- bot_uttered: | ||
utter_name: utter_ask_verify_account_email | ||
- user: It's [email protected] | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_ask_based_in_california | ||
- user: "Yes" | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_ask_verify_account_sufficient_california_income | ||
- user: Why is that your business? | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_california_compliance | ||
- bot_uttered: | ||
utter_name: utter_ask_verify_account_sufficient_california_income | ||
- user: never mind then!! | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_can_do_something_else |
12 changes: 12 additions & 0 deletions
12
e2e_tests_with_assertions/passing/digressions/user_starts_multiple_flows.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
test_cases: | ||
- test_case: user starts multiple flows | ||
steps: | ||
- user: Show my transactions and send money | ||
assertions: | ||
- slot_was_set: | ||
- name: route_session_to_calm | ||
value: True | ||
- bot_uttered: | ||
utter_name: utter_transactions | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_recipient |
12 changes: 12 additions & 0 deletions
12
e2e_tests_with_assertions/passing/digressions/user_starts_with_a_very_long_message.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
test_cases: | ||
- test_case: user starts with a very long message | ||
steps: | ||
- user: What's up dawg, my homie Steven got my back yesterday when we were out for drinks and my phone was out of batt, let me settle up with him. | ||
assertions: | ||
- slot_was_set: | ||
- name: transfer_money_recipient | ||
value: Steven | ||
- name: route_session_to_calm | ||
value: True | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_amount_of_money |
20 changes: 20 additions & 0 deletions
20
e2e_tests_with_assertions/passing/digressions/validation_too_little_money.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
test_cases: | ||
- test_case: validation too little money | ||
steps: | ||
- user: I want to send 5000$ to Martin | ||
assertions: | ||
- slot_was_set: | ||
- name: route_session_to_calm | ||
value: True | ||
- bot_uttered: | ||
utter_name: utter_transfer_money_insufficient_funds | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_amount_of_money | ||
- user: Oh, I thought I had more, then do 3000$ for now | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_final_confirmation | ||
- user: "yes" | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_transfer_complete |
43 changes: 43 additions & 0 deletions
43
...ests_with_assertions/passing/flow_guards/user_tries_to_register_to_vote_in_california.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
metadata: | ||
- duplicate_msg_1: | ||
turn_idx: 1 | ||
- duplicate_msg_2: | ||
turn_idx: 2 | ||
- duplicate_msg_3: | ||
turn_idx: 3 | ||
|
||
test_cases: | ||
|
||
- test_case: user is based in california and wants to register to vote | ||
steps: | ||
- user: I would like to verify my account. | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_ask_verify_account_email | ||
- user: [email protected] | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_ask_based_in_california | ||
- user: "yes" | ||
metadata: duplicate_msg_1 | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_ask_verify_account_sufficient_california_income | ||
- user: "yes" | ||
metadata: duplicate_msg_2 | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_ask_verify_account_confirmation | ||
- user: "yes" | ||
metadata: duplicate_msg_3 | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_verify_account_success | ||
- bot_uttered: | ||
utter_name: utter_can_do_something_else | ||
- user: I would like to register to vote in california. | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_register_to_vote_in_california | ||
- bot_uttered: | ||
utter_name: utter_can_do_something_else |
19 changes: 19 additions & 0 deletions
19
...ns/passing/skip_question/user_tries_to_skip_a_question_and_then_cancels_the_flow_easy.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
test_cases: | ||
- test_case: user tries to skip a question and then cancels the flow (easy) | ||
steps: | ||
- user: send money to John | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_amount_of_money | ||
- user: skip this question | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_skip_question_answer | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_amount_of_money | ||
- user: cancel | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_flow_cancelled_rasa | ||
- bot_uttered: | ||
utter_name: utter_can_do_something_else |
19 changes: 19 additions & 0 deletions
19
.../passing/skip_question/user_tries_to_skip_a_question_and_then_cancels_the_flow_medium.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
test_cases: | ||
- test_case: user tries to skip a question and then cancels the flow (medium) | ||
steps: | ||
- user: send money to John | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_amount_of_money | ||
- user: ask me something else | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_skip_question_answer | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_amount_of_money | ||
- user: one moment, stop that | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_flow_cancelled_rasa | ||
- bot_uttered: | ||
utter_name: utter_can_do_something_else |
33 changes: 33 additions & 0 deletions
33
..._assertions/passing/skip_question/user_tries_to_skip_a_question_multiple_times_medium.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
test_cases: | ||
- test_case: user tries to skip a question multiple times (easy) | ||
steps: | ||
- user: send money to John | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_amount_of_money | ||
- user: ask me something else | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_skip_question_answer | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_amount_of_money | ||
- user: proceed to the next one | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_skip_question_answer | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_amount_of_money | ||
- user: i want to answer next question first | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_skip_question_answer | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_amount_of_money | ||
- user: okay 50 | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_final_confirmation | ||
- user: "yes" | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_transfer_complete |
21 changes: 21 additions & 0 deletions
21
e2e_tests_with_assertions/passing/skip_question/user_tries_to_skip_a_question_once_easy.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
test_cases: | ||
- test_case: user tries to skip a question once (easy) | ||
steps: | ||
- user: send money to John | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_amount_of_money | ||
- user: skip this question | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_skip_question_answer | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_amount_of_money | ||
- user: okay 50 | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_final_confirmation | ||
- user: "yes" | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_transfer_complete |
21 changes: 21 additions & 0 deletions
21
...tests_with_assertions/passing/skip_question/user_tries_to_skip_a_question_once_medium.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
test_cases: | ||
- test_case: user tries to skip a question once (medium) | ||
steps: | ||
- user: send money to John | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_amount_of_money | ||
- user: ask me something else | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_skip_question_answer | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_amount_of_money | ||
- user: okay 50 | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_ask_transfer_money_final_confirmation | ||
- user: "yes" | ||
assertions: | ||
- bot_uttered: | ||
utter_name: utter_transfer_complete |