281 lines
14 KiB
YAML
281 lines
14 KiB
YAML
- config:
|
|
- testset: "account tests"
|
|
|
|
- test:
|
|
- group: "accounts"
|
|
- name: "create account [EN]"
|
|
- url: "/"
|
|
- method: "POST"
|
|
- body: '{"serviceCode": "*483*46#", "phoneNumber": "+254712345678", "sessionId": "AT_Idjhfuvelw64ffbweiy73nd5vnek020", "text": ""}'
|
|
- headers: {'Content-Type': 'application/json'}
|
|
- expected_status: [200]
|
|
- validators:
|
|
- compare: {"header": "content-type", "comparator": "str_eq", "expected":"text/plain"}
|
|
- compare: {"header": "content-length", "comparator": "str_eq", "expected":"175"}
|
|
- compare: {"raw_body":"", "comparator":"contains", expected: "END Your account is being created. You will receive an SMS when your account is ready.\nAkaunti yako ya Sarafu inatayarishwa. Utapokea ujumbe wa SMS akaunti yako ikiwa tayari.\n" }
|
|
|
|
- test:
|
|
- group: "accounts"
|
|
- name: "create account [SW]"
|
|
- url: "/"
|
|
- method: "POST"
|
|
- delay: 2
|
|
- body: '{"serviceCode": "*483*46#", "phoneNumber": "+254712345679", "sessionId": "AT_Idjhfuvelw64ffbweiy73nd5vnek021", "text": ""}'
|
|
- headers: {'Content-Type': 'application/json'}
|
|
- expected_status: [200]
|
|
- validators:
|
|
- compare: {"header": "content-type", "comparator": "str_eq", "expected":"text/plain"}
|
|
- compare: {"header": "content-length", "comparator": "str_eq", "expected":"175"}
|
|
- compare: {"raw_body":"", "comparator":"contains", expected: "END Your account is being created. You will receive an SMS when your account is ready.\nAkaunti yako ya Sarafu inatayarishwa. Utapokea ujumbe wa SMS akaunti yako ikiwa tayari.\n" }
|
|
|
|
- test:
|
|
- group: "accounts"
|
|
- name: "select preferred language prompt [EN]"
|
|
- url: "/"
|
|
- method: "POST"
|
|
- delay: 5 # delay to allow celery tasks to run to create account
|
|
- body: '{"serviceCode": "*483*46#", "phoneNumber": "+254712345678", "sessionId": "AT_Idjhfuvelw64ffbweiy73nd5vnek022", "text": ""}'
|
|
- headers: {'Content-Type': 'application/json'}
|
|
- expected_status: [200]
|
|
- validators:
|
|
- compare: {"header": "content-type", "comparator": "str_eq", "expected":"text/plain"}
|
|
- compare: {"header": "content-length", "comparator": "str_eq", "expected":"53"}
|
|
- compare: {"raw_body":"", "comparator":"str_eq", expected: "CON Welcome to Sarafu\n1. English\n2. Kiswahili\n3. Help"}
|
|
|
|
- test:
|
|
- group: "accounts"
|
|
- name: "select preferred language prompt [SW]"
|
|
- url: "/"
|
|
- method: "POST"
|
|
- delay: 5 # delay to allow celery tasks to run to create account
|
|
- body: '{"serviceCode": "*483*46#", "phoneNumber": "+254712345679", "sessionId": "AT_Idjhfuvelw64ffbweiy73nd5vnek023", "text": ""}'
|
|
- headers: {'Content-Type': 'application/json'}
|
|
- expected_status: [200]
|
|
- validators:
|
|
- compare: {"header": "content-type", "comparator": "str_eq", "expected":"text/plain"}
|
|
- compare: {"header": "content-length", "comparator": "str_eq", "expected":"53"}
|
|
- compare: {"raw_body":"", "comparator":"str_eq", expected: "CON Welcome to Sarafu\n1. English\n2. Kiswahili\n3. Help"}
|
|
|
|
- test:
|
|
- group: "accounts"
|
|
- name: "pin entry [EN]"
|
|
- url: "/"
|
|
- delay: 2 # delay
|
|
- method: "POST"
|
|
- body: '{"serviceCode": "*483*46#", "phoneNumber": "+254712345678", "sessionId": "AT_Idjhfuvelw64ffbweiy73nd5vnek022", "text": "1"}'
|
|
- headers: {'Content-Type': 'application/json'}
|
|
- expected_status: [200]
|
|
- validators:
|
|
- compare: {"header": "content-type", "comparator": "str_eq", "expected":"text/plain"}
|
|
- compare: {"header": "content-length", "comparator": "str_eq", "expected":"54"}
|
|
- compare: {"raw_body":"", "comparator":"str_eq", expected: "CON Please enter a PIN to manage your account.\n0. Back"}
|
|
|
|
- test:
|
|
- group: "accounts"
|
|
- name: "pin entry [SW]"
|
|
- url: "/"
|
|
- delay: 2 # delay
|
|
- method: "POST"
|
|
- body: '{"serviceCode": "*483*46#", "phoneNumber": "+254712345679", "sessionId": "AT_Idjhfuvelw64ffbweiy73nd5vnek023", "text": "2"}'
|
|
- headers: {'Content-Type': 'application/json'}
|
|
- expected_status: [200]
|
|
- validators:
|
|
- compare: {"header": "content-type", "comparator": "str_eq", "expected":"text/plain"}
|
|
- compare: {"header": "content-length", "comparator": "str_eq", "expected":"59"}
|
|
- compare: {"raw_body":"", "comparator":"str_eq", expected: "CON Tafadhali weka PIN ili kudhibiti akaunti yako.\n0. Nyuma"}
|
|
|
|
- test:
|
|
- group: "accounts"
|
|
- name: "pin entry confirmation [EN]"
|
|
- url: "/"
|
|
- delay: 2 # delay
|
|
- method: "POST"
|
|
- body: '{"serviceCode": "*483*46#", "phoneNumber": "+254712345678", "sessionId": "AT_Idjhfuvelw64ffbweiy73nd5vnek022", "text": "1*0000"}'
|
|
- headers: {'Content-Type': 'application/json'}
|
|
- expected_status: [200]
|
|
- validators:
|
|
- compare: {"header": "content-type", "comparator": "str_eq", "expected":"text/plain"}
|
|
- compare: {"header": "content-length", "comparator": "str_eq", "expected":"32"}
|
|
- compare: {"raw_body":"", "comparator":"str_eq", expected: "CON Enter your PIN again\n0. Back"}
|
|
|
|
- test:
|
|
- group: "accounts"
|
|
- name: "pin entry confirmation [SW]"
|
|
- url: "/"
|
|
- delay: 2 # delay
|
|
- method: "POST"
|
|
- body: '{"serviceCode": "*483*46#", "phoneNumber": "+254712345679", "sessionId": "AT_Idjhfuvelw64ffbweiy73nd5vnek023", "text": "2*1111"}'
|
|
- headers: {'Content-Type': 'application/json'}
|
|
- expected_status: [200]
|
|
- validators:
|
|
- compare: {"header": "content-type", "comparator": "str_eq", "expected":"text/plain"}
|
|
- compare: {"header": "content-length", "comparator": "str_eq", "expected":"31"}
|
|
- compare: {"raw_body":"", "comparator":"str_eq", expected: "CON Weka PIN yako tena\n0. Nyuma"}
|
|
|
|
- test:
|
|
- group: "accounts"
|
|
- name: "given names entry[EN]"
|
|
- url: "/"
|
|
- delay: 3 # delay
|
|
- method: "POST"
|
|
- body: '{"serviceCode": "*483*46#", "phoneNumber": "+254712345678", "sessionId": "AT_Idjhfuvelw64ffbweiy73nd5vnek022", "text": "1*0000*0000"}'
|
|
- headers: {'Content-Type': 'application/json'}
|
|
- expected_status: [200]
|
|
- validators:
|
|
- compare: {"header": "content-type", "comparator": "str_eq", "expected":"text/plain"}
|
|
- compare: {"header": "content-length", "comparator": "str_eq", "expected":"28"}
|
|
- compare: {"raw_body":"", "comparator":"str_eq", expected: "CON Enter first name\n0. Back"}
|
|
|
|
- test:
|
|
- group: "accounts"
|
|
- name: "given names entry[SW]"
|
|
- url: "/"
|
|
- delay: 3 # delay
|
|
- method: "POST"
|
|
- body: '{"serviceCode": "*483*46#", "phoneNumber": "+254712345679", "sessionId": "AT_Idjhfuvelw64ffbweiy73nd5vnek023", "text": "2*1111*1111"}'
|
|
- headers: {'Content-Type': 'application/json'}
|
|
- expected_status: [200]
|
|
- validators:
|
|
- compare: {"header": "content-type", "comparator": "str_eq", "expected":"text/plain"}
|
|
- compare: {"header": "content-length", "comparator": "str_eq", "expected":"37"}
|
|
- compare: {"raw_body":"", "comparator":"str_eq", expected: "CON Weka jina lako la kwanza\n0. Nyuma"}
|
|
|
|
- test:
|
|
- group: "accounts"
|
|
- name: "family name entry[EN]"
|
|
- url: "/"
|
|
- delay: 2 # delay
|
|
- method: "POST"
|
|
- body: '{"serviceCode": "*483*46#", "phoneNumber": "+254712345678", "sessionId": "AT_Idjhfuvelw64ffbweiy73nd5vnek022", "text": "1*0000*0000*Kimani"}'
|
|
- headers: {'Content-Type': 'application/json'}
|
|
- expected_status: [200]
|
|
- validators:
|
|
- compare: {"header": "content-type", "comparator": "str_eq", "expected":"text/plain"}
|
|
- compare: {"header": "content-length", "comparator": "str_eq", "expected":"27"}
|
|
- compare: {"raw_body":"", "comparator":"str_eq", expected: "CON Enter last name\n0. Back"}
|
|
|
|
- test:
|
|
- group: "accounts"
|
|
- name: "family name entry[SW]"
|
|
- url: "/"
|
|
- delay: 2 # delay
|
|
- method: "POST"
|
|
- body: '{"serviceCode": "*483*46#", "phoneNumber": "+254712345679", "sessionId": "AT_Idjhfuvelw64ffbweiy73nd5vnek023", "text": "2*1111*1111*Chebet"}'
|
|
- headers: {'Content-Type': 'application/json'}
|
|
- expected_status: [200]
|
|
- validators:
|
|
- compare: {"header": "content-type", "comparator": "str_eq", "expected":"text/plain"}
|
|
- compare: {"header": "content-length", "comparator": "str_eq", "expected":"37"}
|
|
- compare: {"raw_body":"", "comparator":"str_eq", expected: "CON Weka jina lako la mwisho\n0. Nyuma"}
|
|
|
|
- test:
|
|
- group: "accounts"
|
|
- name: "gender selection[EN]"
|
|
- url: "/"
|
|
- delay: 2 # delay
|
|
- method: "POST"
|
|
- body: '{"serviceCode": "*483*46#", "phoneNumber": "+254712345678", "sessionId": "AT_Idjhfuvelw64ffbweiy73nd5vnek022", "text": "1*0000*0000*Kimani*Omollo"}'
|
|
- headers: {'Content-Type': 'application/json'}
|
|
- expected_status: [200]
|
|
- validators:
|
|
- compare: {"header": "content-type", "comparator": "str_eq", "expected":"text/plain"}
|
|
- compare: {"header": "content-length", "comparator": "str_eq", "expected":"42"}
|
|
- compare: {"raw_body":"", "comparator":"str_eq", expected: "CON Enter gender\n1. Male\n2. Female\n0. Back"}
|
|
|
|
- test:
|
|
- group: "accounts"
|
|
- name: "gender selection[SW]"
|
|
- url: "/"
|
|
- delay: 2 # delay
|
|
- method: "POST"
|
|
- body: '{"serviceCode": "*483*46#", "phoneNumber": "+254712345679", "sessionId": "AT_Idjhfuvelw64ffbweiy73nd5vnek023", "text": "2*1111*1111*Chebet*Musau"}'
|
|
- headers: {'Content-Type': 'application/json'}
|
|
- expected_status: [200]
|
|
- validators:
|
|
- compare: {"header": "content-type", "comparator": "str_eq", "expected":"text/plain"}
|
|
- compare: {"header": "content-length", "comparator": "str_eq", "expected":"53"}
|
|
- compare: {"raw_body":"", "comparator":"str_eq", expected: "CON Weka jinsia yako\n1. Mwanaume\n2. Mwanamke\n0. Nyuma"}
|
|
|
|
- test:
|
|
- group: "accounts"
|
|
- name: "location entry[EN]"
|
|
- url: "/"
|
|
- delay: 2 # delay
|
|
- method: "POST"
|
|
- body: '{"serviceCode": "*483*46#", "phoneNumber": "+254712345678", "sessionId": "AT_Idjhfuvelw64ffbweiy73nd5vnek022", "text": "1*0000*0000*Kimani*Omollo*1"}'
|
|
- headers: {'Content-Type': 'application/json'}
|
|
- expected_status: [200]
|
|
- validators:
|
|
- compare: {"header": "content-type", "comparator": "str_eq", "expected":"text/plain"}
|
|
- compare: {"header": "content-length", "comparator": "str_eq", "expected":"26"}
|
|
- compare: {"raw_body":"", "comparator":"str_eq", expected: "CON Enter location\n0. Back"}
|
|
|
|
- test:
|
|
- group: "accounts"
|
|
- name: "location entry[SW]"
|
|
- url: "/"
|
|
- delay: 2 # delay
|
|
- method: "POST"
|
|
- body: '{"serviceCode": "*483*46#", "phoneNumber": "+254712345679", "sessionId": "AT_Idjhfuvelw64ffbweiy73nd5vnek023", "text": "2*1111*1111*Chebet*Musau*2"}'
|
|
- headers: {'Content-Type': 'application/json'}
|
|
- expected_status: [200]
|
|
- validators:
|
|
- compare: {"header": "content-type", "comparator": "str_eq", "expected":"text/plain"}
|
|
- compare: {"header": "content-length", "comparator": "str_eq", "expected":"27"}
|
|
- compare: {"raw_body":"", "comparator":"str_eq", expected: "CON Weka eneo lako\n0. Nyuma"}
|
|
|
|
- test:
|
|
- group: "accounts"
|
|
- name: "product entry[EN]"
|
|
- url: "/"
|
|
- delay: 2 # delay
|
|
- method: "POST"
|
|
- body: '{"serviceCode": "*483*46#", "phoneNumber": "+254712345678", "sessionId": "AT_Idjhfuvelw64ffbweiy73nd5vnek022", "text": "1*0000*0000*Kimani*Omollo*1*Kangemi"}'
|
|
- headers: {'Content-Type': 'application/json'}
|
|
- expected_status: [200]
|
|
- validators:
|
|
- compare: {"header": "content-type", "comparator": "str_eq", "expected":"text/plain"}
|
|
- compare: {"header": "content-length", "comparator": "str_eq", "expected":"55"}
|
|
- compare: {"raw_body":"", "comparator":"str_eq", expected: "CON Please enter a product or service you offer\n0. Back"}
|
|
|
|
- test:
|
|
- group: "accounts"
|
|
- name: "product entry[SW]"
|
|
- url: "/"
|
|
- delay: 2 # delay
|
|
- method: "POST"
|
|
- body: '{"serviceCode": "*483*46#", "phoneNumber": "+254712345679", "sessionId": "AT_Idjhfuvelw64ffbweiy73nd5vnek023", "text": "2*1111*1111*Chebet*Musau*2*Chebarbar"}'
|
|
- headers: {'Content-Type': 'application/json'}
|
|
- expected_status: [200]
|
|
- validators:
|
|
- compare: {"header": "content-type", "comparator": "str_eq", "expected":"text/plain"}
|
|
- compare: {"header": "content-length", "comparator": "str_eq", "expected":"52"}
|
|
- compare: {"raw_body":"", "comparator":"str_eq", expected: "CON Tafadhali weka bidhaa ama huduma unauza\n0. Nyuma"}
|
|
|
|
- test:
|
|
- group: "accounts"
|
|
- name: "start menu[EN]"
|
|
- url: "/"
|
|
- delay: 2 # delay
|
|
- method: "POST"
|
|
- body: '{"serviceCode": "*483*46#", "phoneNumber": "+254712345678", "sessionId": "AT_Idjhfuvelw64ffbweiy73nd5vnek022", "text": "1*0000*0000*Kimani*Omollo*1*Kangemi*Potatoes"}'
|
|
- headers: {'Content-Type': 'application/json'}
|
|
- expected_status: [200]
|
|
- validators:
|
|
- compare: {"header": "content-type", "comparator": "str_eq", "expected":"text/plain"}
|
|
- compare: {"header": "content-length", "comparator": "str_eq", "expected":"51"}
|
|
- compare: {"raw_body":"", "comparator":"str_eq", expected: "CON Balance 50.00 SRF\n1. Send\n2. My Account\n3. Help"}
|
|
|
|
- test:
|
|
- group: "accounts"
|
|
- name: "start menu[EN]"
|
|
- url: "/"
|
|
- delay: 2 # delay
|
|
- method: "POST"
|
|
- body: '{"serviceCode": "*483*46#", "phoneNumber": "+254712345679", "sessionId": "AT_Idjhfuvelw64ffbweiy73nd5vnek023", "text": "2*1111*1111*Chebet*Musau*2*Musau*Mandazi"}'
|
|
- headers: {'Content-Type': 'application/json'}
|
|
- expected_status: [200]
|
|
- validators:
|
|
- compare: {"header": "content-type", "comparator": "str_eq", "expected":"text/plain"}
|
|
- compare: {"header": "content-length", "comparator": "str_eq", "expected":"56"}
|
|
- compare: {"raw_body":"", "comparator":"str_eq", expected: "CON Salio 50.00 SRF\n1. Tuma\n2. Akaunti yangu\n3. Usaidizi"} |