Categories:
Configuration of user’s data
Guidelines for the configuration of of Aura users required to launch the QA tests
Introduction
The configuration of the different Aura’s users is required in order to launch the QA Tool.
When the QA tests are executed, the system recovers the users’ data from Telefónica Kernel APIs and stores it in the path:
~/[project_folder]/aura-tests/acceptance/_output/users/[country_code]/
At this stage, the local QA team must create a new file for the configuration of users in the following path:
~/[project_folder]/aura-tests/acceptance/settings/[country_code]/[country_code]-[environment]-local-users.json
This file must be edited with the sections and procedure detailed in the following sections.
Fields in the file [country_code]-[environment]-local-users.json
The required steps to fill in this file with the users’ configuration are fully explained below.
user_definition field
Firstly, it is required to fill in the user_definition field:
subscription_type: subscription type of users, it can be ‘prepaid’, ‘postpaid’ or ‘control’)msisdn: phone number of the useruser_id: id of user in Telefónica Kerneluser_type: user type, it can be ‘monomsisdn’, ‘multimsisdn’, ’nomsisdn’, ‘invalid’uid: user identification (used for authentication purposes)email: email address of user (used for authentication purposes)password: uid/email password (used for authentication purposes)
ℹ️ In environments with mandatory authorization_id, the user can authenticate through:
- MSISDN
- Uid + password
- Email + password
If possible, add both fields, uid and email or add SKIP value to avoid authentication failures (if it is impossible, obtain the uid and/or email of the user), as tests with this user will be skipped.
See more details in Troubleshooting: Error related to users’ config file.
Example of definition
"users_definition": {
"user1": {
"subscription_type": "prepaid",
"user_type": "monomsisdn",
"msisdn": "+573152641455",
"userid": "50914",
“login_user”: “navx@o2.com”,
“login_password”: “test1234”
},
"user2": {
"subscription_type": "postpaid",
"user_type": "monomsisdn",
"msisdn": "+573156492873",
"userid": "50908",
"uid": "509652361",
"email": user2@gmail.com,
"password": "user2pwd"
},
"user3": {
"subscription_type": "control",
"user_type": "monomsisdn",
"msisdn": "+573102553679",
"userid": "50913"
"uid": "509090909",
"password": "user3pwd"
},
"user4": {
"subscription_type": "postpaid",
"user_type": "multimsisdn",
"msisdn": "+573167412035",
"userid": "50739"
"email": user4@gmail.com,
"password": "user4pwd"
},
"user5": {
"subscription_type": "control",
"user_type": "multimsisdn",
"msisdn": "+573152445674",
"userid": "50911"
},
"user6": {
"subscription_type": "postpaid",
"user_type": "monomsisdn",
"msisdn": "999999999",
"userid": "999999999"
},
"user7": {
"subscription_type": "prepaid",
"user_type": "monomsisdn",
"msisdn": "",
"userid": "50914"
}
}
users element
It is required to fill in the users’ definition name in the users element. For this purpose, there are different types of users, depending on the type of data that the user has on Telefónica Kernel.
Default user
Main user executed in tests, independently on the type of data.
Contract type
user_profileendpoint configured in Telefónica Kernel (element identities.services)users.common.prepaid: Value of the service is ‘mobile_prepaid’users.common.postpaid: Value of the service is ‘mobile_postpaid’users.common.control: Value of the service element is ‘mobile_control’
Example of user profile call
"id_document": {
"country": "ES",
"type": "NIF",
"value": "6667337566Y"
},
"identities": [
{
"type": "uid",
"id": "412d606f-4937-443b-b5e7-a8d0f63ef0bc",
"services": [
"authentication"
],
"roles": [
"owner"
]
},
{
"type": "uid",
"id": "8971245361267438349",
"services": [
"iptv"
],
"roles": [
"owner"
],
"group_ids": [
"bundle_1"
]
},
{
"type": "phone_number",
"id": "+34629123456",
"services": [
"mobile_postpaid"
],
"roles": [
"owner",
"admin"
],
"group_ids": [
"bundle_1"
]
},
{
"type": "phone_number",
"id": "+34609332266",
"services": [
"mobile_postpaid"
],
"roles": [
"owner"
],
"group_ids": [
"bundle_1"
]
},
{
"type": "phone_number",
"id": "+34983456789",
"services": [
"landline",
"internet"
],
"roles": [
"owner"
],
"group_ids": [
"bundle_1"
]
}
],
"name": "Andrés Iniesta",
"contact_media": [
{
"type": "phone_number",
"value": "+34629123456"
}
],
"id": "412d606f-4937-443b-b5e7-a8d0f63ef0bc"
}
User type
user_profile endpoint configured on Telefónica Kernel (in the element identities.services).
Four types of users are defined:
-
monomsisdn User that only has one phone. In this case, it is possible to classify the user by subscription type:
users.prepaid: user type monomsisdn whose phone number is prepaidusers.postpaid: user type monomsisdn whose phone number is postpaidusers.control: user type monomsisdn whose phone number is control
-
multimsisdn: User that has several phones. In this case, it is possible to classify the user by subscription type:
users.multimsisdn.prepaid: user type multimsisdn whose phone number is prepaidusers.multimsisdn.postpaid: user type multimsisdn whose phone number is postpaidusers.multimsisdn.control: user type multimsisdn whose phone number is control
-
nomsisdn: User with no phone number.
-
invalid: Invalid user in Telefónica Kernel and Aura.
balance_check
It can be checked in mobile_balance and mobile_quota endpoints configured on Telefónica Kernel. User should have data in mobile_balance endpoint, for example:
{
"phone_number": "+5567999170892",
"expiration_date": "2019-03-08T09:42:51Z",
"amount": 44.17,
"currency": "BRL"
}
users.balance_check.voice_data
User with voice and data in mobile quota endpoint.
Example of mobile quota:
{
"phone_number": "+541121700177",
"sms": [
{
"consumed_sms": 0,
"max_sms": 25000,
"description": "SMS",
"end_date": "2018-12-17T03:00:00Z",
"start_date": "2018-11-18T03:00:00Z"
}
],
"voice": [
{
"description": "Minutos Multidestino No Acumulable",
"end_date": "2018-12-17T03:00:00Z",
"consumed_seconds": 3448,
"max_seconds": 30000,
"start_date": "2018-11-18T03:00:00Z",
"destinations": [
"any"
]
},
{
"description": "Minutos a Comunidad",
"end_date": "2018-12-17T03:00:00Z",
"consumed_seconds": 75336,
"max_seconds": 3000000,
"start_date": "2018-11-18T03:00:00Z",
"destinations": [
"telefonica"
]
}
],
"data": [
{
"max_bytes": 4294967296,
"consumed_bytes": 1230395392,
"description": "Datos Incluidos/Velocidad",
"end_date": "2018-12-17T03:00:00Z",
"start_date": "2018-11-18T03:00:00Z"
}
]
}
users.balance_check.no_voice
User without voice element in mobile quota endpoint.
Example of mobile quota data:
{
"phone_number": "+541121700177",
"sms": [
{
"consumed_sms": 0,
"max_sms": 25000,
"description": "SMS",
"end_date": "2018-12-17T03:00:00Z",
"start_date": "2018-11-18T03:00:00Z"
}
],
"voice": [],
"data": [
{
"max_bytes": 4294967296,
"consumed_bytes": 1230395392,
"description": "Datos Incluidos/Velocidad",
"end_date": "2018-12-17T03:00:00Z",
"start_date": "2018-11-18T03:00:00Z"
}
]
}
-
users.balance_check.multiple_mobiles
User with multiple mobiles insubscribed_productsendpoint. -
users.balance_check.bonus_balance
User with several bonus contracted.
Example of mobile quota:
{
"phone_number": "+5511982099898",
"sms": [],
"voice": [],
"data": [
{
"max_bytes": 53689188352,
"consumed_bytes": 1506646425,
"description": "MULTIVIVO GRATIS.",
"end_date": "2019-01-01T02:00:00Z",
"start_date": "2018-12-02T02:00:00Z"
},
{
"max_bytes": 524288000,
"consumed_bytes": 524288000,
"description": "BONUS CONTA DIGITAL",
"end_date": "2019-01-01T02:00:00Z",
"start_date": "2018-12-02T02:00:00Z"
},
{
"max_bytes": 524288000,
"consumed_bytes": 524288000,
"description": "BONUS DEBITO AUTOMATICO",
"end_date": "2019-01-01T02:00:00Z",
"start_date": "2018-12-02T02:00:00Z"
},
{
"max_bytes": 51215052308,
"consumed_bytes": 0,
"description": "Vivo Bis",
"end_date": "2019-01-01T02:00:00Z",
"start_date": "2018-12-02T02:00:00Z"
},
{
"max_bytes": 53687091200,
"consumed_bytes": 326620938,
"description": "App Facilidades",
"end_date": "2019-01-01T02:00:00Z",
"start_date": "2018-12-02T02:00:00Z"
},
{
"max_bytes": 42949672960,
"consumed_bytes": 14754460467,
"description": "Double Play",
"end_date": "2019-01-01T02:00:00Z",
"start_date": "2018-12-02T02:00:00Z"
}
]
}
users.balance_check.no_balance
Example of mobile balance data:
{
"phone_number": "+541121700177",
"expiration_date": "2019-03-06T13:45:33Z",
"amount": 0,
"currency": "ARS"
}
-
users.balance_check.start_date
User withstart_datein mobile quota. -
users.balance_check.no_start_date
User with nostart_datein mobile quota.
Example of mobile quota:
{
"phone_number": "+541121700177",
"sms": [
{
"consumed_sms": 0,
"max_sms": 25000,
"description": "SMS",
"end_date": "2018-12-17T03:00:00Z",
"start_date": "2018-11-18T03:00:00Z"
}
],
"voice": [
{
"description": "Minutos Multidestino No Acumulable",
"end_date": "2018-12-17T03:00:00Z",
"consumed_seconds": 3448,
"max_seconds": 30000,
"destinations": [
"any"
]
},
{
"description": "Minutos a Comunidad",
"end_date": "2018-12-17T03:00:00Z",
"consumed_seconds": 75336,
"max_seconds": 3000000,
"destinations": [
"telefonica"
]
}
],
"data": [
{
"max_bytes": 4294967296,
"consumed_bytes": 1230395392,
"description": "Datos Incluidos/Velocidad",
"end_date": "2018-12-17T03:00:00Z",
}
]
}
users.balance_check.today_expiration
User in which theexpiration_dateelement in mobile balance endpoint is today.
{
"phone_number": "+541121700177",
"expiration_date": "{today}",
"amount": 0,
"currency": "ARS"
}