Commit 634157fb45c259a422978acec8a4b7fbcb38af42

Authored by Yurii Mykhalchuk
Committed by GitHub
2 parents 6c9c70de 6d912ba6

Merge pull request #288 from mykhaly/devel

Make global/suite variables uppercase (second patch)
@@ -19,9 +19,9 @@ Library openprocurement_client_helper.py @@ -19,9 +19,9 @@ Library openprocurement_client_helper.py
19 Підготувати клієнт для користувача 19 Підготувати клієнт для користувача
20 [Arguments] ${username} 20 [Arguments] ${username}
21 [Documentation] Відкрити браузер, створити об’єкт api wrapper, тощо 21 [Documentation] Відкрити браузер, створити об’єкт api wrapper, тощо
22 - Log ${api_host_url}  
23 - Log ${api_version}  
24 - ${api_wrapper}= prepare_api_wrapper ${USERS.users['${username}'].api_key} ${api_host_url} ${api_version} 22 + Log ${API_HOST_URL}
  23 + Log ${API_VERSION}
  24 + ${api_wrapper}= prepare_api_wrapper ${USERS.users['${username}'].api_key} ${API_HOST_URL} ${API_VERSION}
25 Set To Dictionary ${USERS.users['${username}']} client=${api_wrapper} 25 Set To Dictionary ${USERS.users['${username}']} client=${api_wrapper}
26 Set To Dictionary ${USERS.users['${username}']} access_token=${EMPTY} 26 Set To Dictionary ${USERS.users['${username}']} access_token=${EMPTY}
27 ${id_map}= Create Dictionary 27 ${id_map}= Create Dictionary
@@ -85,7 +85,7 @@ Library openprocurement_client_helper.py @@ -85,7 +85,7 @@ Library openprocurement_client_helper.py
85 Set To Dictionary ${tender['data']} status=${status} 85 Set To Dictionary ${tender['data']} status=${status}
86 ${tender}= Call Method ${USERS.users['${username}'].client} patch_tender ${tender} 86 ${tender}= Call Method ${USERS.users['${username}'].client} patch_tender ${tender}
87 Log ${tender} 87 Log ${tender}
88 - Log ${\n}${api_host_url}/api/${api_version}/tenders/${tender.data.id}${\n} WARN 88 + Log ${\n}${API_HOST_URL}/api/${API_VERSION}/tenders/${tender.data.id}${\n} WARN
89 Set To Dictionary ${USERS.users['${username}']} access_token=${access_token} 89 Set To Dictionary ${USERS.users['${username}']} access_token=${access_token}
90 Set To Dictionary ${USERS.users['${username}']} tender_data=${tender} 90 Set To Dictionary ${USERS.users['${username}']} tender_data=${tender}
91 Log ${USERS.users['${username}'].tender_data} 91 Log ${USERS.users['${username}'].tender_data}
@@ -35,7 +35,7 @@ Set Suite Variable With Default Value @@ -35,7 +35,7 @@ Set Suite Variable With Default Value
35 35
36 36
37 Порівняти системний і серверний час 37 Порівняти системний і серверний час
38 - ${server_time}= request ${api_host_url} HEAD 38 + ${server_time}= request ${API_HOST_URL} HEAD
39 ${local_time}= Get current TZdate 39 ${local_time}= Get current TZdate
40 Log ${server_time.headers['date']} 40 Log ${server_time.headers['date']}
41 Log ${local_time} 41 Log ${local_time}
@@ -60,8 +60,8 @@ Set Suite Variable With Default Value @@ -60,8 +60,8 @@ Set Suite Variable With Default Value
60 60
61 61
62 Завантажуємо дані про користувачів і майданчики 62 Завантажуємо дані про користувачів і майданчики
63 - Log ${broker}  
64 - Log ${role} 63 + Log ${BROKER}
  64 + Log ${ROLE}
65 # Suite variable; should be present in every test suite 65 # Suite variable; should be present in every test suite
66 # in `*** Variables ***` section 66 # in `*** Variables ***` section
67 Log Many @{USED_ROLES} 67 Log Many @{USED_ROLES}
@@ -83,13 +83,13 @@ Set Suite Variable With Default Value @@ -83,13 +83,13 @@ Set Suite Variable With Default Value
83 ${used_users}= Create List 83 ${used_users}= Create List
84 84
85 # Handle `-v role:something` 85 # Handle `-v role:something`
86 - Run Keyword Unless '${role}' in @{USED_ROLES} 86 + Run Keyword Unless '${ROLE}' in @{USED_ROLES}
87 ... Log 87 ... Log
88 - ... Role ${role} is not used in this test suite. 88 + ... Role ${ROLE} is not used in this test suite.
89 ... WARN 89 ... WARN
90 Set Suite Variable With Default Value 90 Set Suite Variable With Default Value
91 - ... ${role}  
92 - ... ${BROKERS['${broker}'].roles.${role}} 91 + ... ${ROLE}
  92 + ... ${BROKERS['${BROKER}'].roles.${ROLE}}
93 93
94 # Set default value for each role if it is not set yet; 94 # Set default value for each role if it is not set yet;
95 # fill `used_users`; 95 # fill `used_users`;
@@ -161,7 +161,7 @@ Get Broker Property By Username @@ -161,7 +161,7 @@ Get Broker Property By Username
161 161
162 Створити артефакт 162 Створити артефакт
163 ${artifact}= Create Dictionary 163 ${artifact}= Create Dictionary
164 - ... api_version=${api_version} 164 + ... api_version=${API_VERSION}
165 ... tender_uaid=${TENDER['TENDER_UAID']} 165 ... tender_uaid=${TENDER['TENDER_UAID']}
166 ... last_modification_date=${TENDER['LAST_MODIFICATION_DATE']} 166 ... last_modification_date=${TENDER['LAST_MODIFICATION_DATE']}
167 ... mode=${MODE} 167 ... mode=${MODE}
1 *** Variables *** 1 *** Variables ***
2 -${api_host_url} https://lb.api-sandbox.openprocurement.org  
3 -${api_version} 2.3  
4 -${broker} Quinta  
5 -${role} viewer 2 +${API_HOST_URL} https://lb.api-sandbox.openprocurement.org
  3 +${API_VERSION} 2.3
  4 +${BROKER} Quinta
  5 +${ROLE} viewer
Please register or login to post a comment