Showing
2 changed files
with
21 additions
and
13 deletions
... | ... | @@ -68,14 +68,6 @@ Library openprocurement_client_helper.py |
68 | 68 | Log ${username} |
69 | 69 | Log ${field_name} |
70 | 70 | |
71 | - ${status} ${field_value}= Run keyword and ignore error | |
72 | - ... Get from object | |
73 | - ... ${USERS.users['${username}'].tender_data.data} | |
74 | - ... ${field_name} | |
75 | - # If field is found, return its value | |
76 | - Run Keyword if '${status}' == 'PASS' Return from keyword ${field_value} | |
77 | - | |
78 | - # Else refresh cached data and try again | |
79 | 71 | openprocurement_client.Пошук тендера по ідентифікатору |
80 | 72 | ... ${username} |
81 | 73 | ... ${TENDER['TENDER_UAID']} |
... | ... | @@ -86,7 +78,6 @@ Library openprocurement_client_helper.py |
86 | 78 | ... ${field_name} |
87 | 79 | Run Keyword if '${status}' == 'PASS' Return from keyword ${field_value} |
88 | 80 | |
89 | - # If field is still absent, trigger a failure | |
90 | 81 | Fail Field not found: ${field_name} |
91 | 82 | |
92 | 83 | ... | ... |
... | ... | @@ -260,11 +260,10 @@ Get Broker Property By Username |
260 | 260 | |
261 | 261 | Звірити поле тендера із значенням |
262 | 262 | [Arguments] ${username} ${left} ${field} |
263 | - ${right}= Викликати для учасника ${username} Отримати інформацію із тендера ${field} | |
263 | + ${right}= Отримати дані із тендера ${username} ${field} | |
264 | 264 | Log ${left} |
265 | 265 | Log ${right} |
266 | 266 | Порівняти об'єкти ${left} ${right} |
267 | - Set_To_Object ${USERS.users['${username}'].tender_data.data} ${field} ${left} | |
268 | 267 | |
269 | 268 | |
270 | 269 | Порівняти об'єкти |
... | ... | @@ -284,9 +283,8 @@ Get Broker Property By Username |
284 | 283 | |
285 | 284 | Звірити дату тендера із значенням |
286 | 285 | [Arguments] ${username} ${left} ${field} |
287 | - ${right}= Викликати для учасника ${username} Отримати інформацію із тендера ${field} | |
286 | + ${right}= Отримати дані із тендера ${username} ${field} | |
288 | 287 | Порівняти дати ${left} ${right} |
289 | - Set_To_Object ${USERS.users['${username}'].tender_data.data} ${field} ${left} | |
290 | 288 | |
291 | 289 | |
292 | 290 | Порівняти дати |
... | ... | @@ -337,6 +335,25 @@ Get Broker Property By Username |
337 | 335 | ... WARN |
338 | 336 | Run Keyword And Return Run As ${username} ${command} @{arguments} |
339 | 337 | |
338 | +Отримати дані із тендера | |
339 | + [Arguments] ${username} ${field_name} | |
340 | + Log ${username} | |
341 | + Log ${field_name} | |
342 | + | |
343 | + ${status} ${field_value}= Run keyword and ignore error | |
344 | + ... Get from object | |
345 | + ... ${USERS.users['${username}'].tender_data.data} | |
346 | + ... ${field_name} | |
347 | + # If field in cache, return its value | |
348 | + Run Keyword if '${status}' == 'PASS' Return from keyword ${field_value} | |
349 | + # Else call broker to find field | |
350 | + ${field_value}= Викликати для учасника ${username} Отримати інформацію із тендера ${field_name} | |
351 | + # And caching its value before return | |
352 | + Set_To_Object ${USERS.users['${username}'].tender_data.data} ${field_name} ${field_value} | |
353 | + [return] ${field_value} | |
354 | + | |
355 | + | |
356 | + | |
340 | 357 | |
341 | 358 | Run As |
342 | 359 | [Arguments] ${username} ${command} @{arguments} | ... | ... |
Please
register
or
login
to post a comment