Commit e2281db2c22ba9a3eb5e658d3af54fed35b97091

Authored by Andrew Yanovych
1 parent 9bfc1ccc

added ketwords for uploading document to bid, fixed issues in keywords

@@ -13,13 +13,14 @@ ${question_id} 0 @@ -13,13 +13,14 @@ ${question_id} 0
13 ${api_wrapper}= prepare_api_wrapper ${USERS.users['${ARGUMENTS[0]}'].api_key} ${API_HOST_URL} ${api_version} 13 ${api_wrapper}= prepare_api_wrapper ${USERS.users['${ARGUMENTS[0]}'].api_key} ${API_HOST_URL} ${api_version}
14 Set To Dictionary ${USERS.users['${ARGUMENTS[0]}']} client ${api_wrapper} 14 Set To Dictionary ${USERS.users['${ARGUMENTS[0]}']} client ${api_wrapper}
15 Log Variables 15 Log Variables
16 - 16 +
  17 +Підготувати дані для оголошення тендера
  18 + ${INITIAL_TENDER_DATA}= prepare_test_tender_data
  19 + [return] ${INITIAL_TENDER_DATA}
17 20
18 Створити тендер 21 Створити тендер
19 [Arguments] @{ARGUMENTS} 22 [Arguments] @{ARGUMENTS}
20 - ${INITIAL_TENDER_DATA}= prepare_test_tender_data  
21 - Log object data ${INITIAL_TENDER_DATA}  
22 - ${TENDER_DATA}= Call Method ${USERS.users['${ARGUMENTS[0]}'].client} create_tender ${INITIAL_TENDER_DATA} 23 + ${TENDER_DATA}= Call Method ${USERS.users['${ARGUMENTS[0]}'].client} create_tender ${ARGUMENTS[1]}
23 Log object data ${TENDER_DATA} cteated_tender 24 Log object data ${TENDER_DATA} cteated_tender
24 ${access_token}= Get Variable Value ${TENDER_DATA.access.token} 25 ${access_token}= Get Variable Value ${TENDER_DATA.access.token}
25 Set Global Variable ${access_token} 26 Set Global Variable ${access_token}
@@ -41,7 +42,7 @@ ${question_id} 0 @@ -41,7 +42,7 @@ ${question_id} 0
41 Log access_token: ${access_token} 42 Log access_token: ${access_token}
42 Log tender_id: ${TENDER_DATA.data.id} 43 Log tender_id: ${TENDER_DATA.data.id}
43 Set Global Variable ${TENDER_DATA} 44 Set Global Variable ${TENDER_DATA}
44 - [return] ${TENDER_DATA} 45 + [return] ${TENDER_DATA}
45 46
46 Пошук тендера по ідентифікатору 47 Пошук тендера по ідентифікатору
47 [Arguments] @{ARGUMENTS} 48 [Arguments] @{ARGUMENTS}
@@ -68,7 +69,9 @@ ${question_id} 0 @@ -68,7 +69,9 @@ ${question_id} 0
68 [Documentation] 69 [Documentation]
69 ... ${ARGUMENTS[0]} == username 70 ... ${ARGUMENTS[0]} == username
70 ... ${ARGUMENTS[1]} == fieldname 71 ... ${ARGUMENTS[1]} == fieldname
  72 + log ${ARGUMENTS}
71 ${field_value}= Get_From_Object ${USERS.users['${ARGUMENTS[0]}'].tender_data.data} ${ARGUMENTS[1]} 73 ${field_value}= Get_From_Object ${USERS.users['${ARGUMENTS[0]}'].tender_data.data} ${ARGUMENTS[1]}
  74 + log ${field_value}
72 [return] ${field_value} 75 [return] ${field_value}
73 76
74 77
@@ -134,13 +137,16 @@ ${question_id} 0 @@ -134,13 +137,16 @@ ${question_id} 0
134 [Documentation] 137 [Documentation]
135 ... ${ARGUMENTS[0]} == username 138 ... ${ARGUMENTS[0]} == username
136 ... ${ARGUMENTS[1]} == tender_uid 139 ... ${ARGUMENTS[1]} == tender_uid
137 - ... ${ARGUMENTS[2]} == question 140 + ... ${ARGUMENTS[2]} == bid
138 [Arguments] @{ARGUMENTS} 141 [Arguments] @{ARGUMENTS}
139 log many @{ARGUMENTS} 142 log many @{ARGUMENTS}
140 ${tender}= Call Method ${USERS.users['${ARGUMENTS[0]}'].client} get_tender ${ARGUMENTS[1]} 143 ${tender}= Call Method ${USERS.users['${ARGUMENTS[0]}'].client} get_tender ${ARGUMENTS[1]}
141 - ${question}= Call Method ${USERS.users['${ARGUMENTS[0]}'].client} create_question ${tender} ${ARGUMENTS[2]}  
142 - Log object data ${question} question  
143 - 144 + log ${USERS.users['${ARGUMENTS[0]}']}
  145 + ${tender}= set_access_key ${tender} ${USERS.users['${ARGUMENTS[0]}'].api_key}
  146 + log ${tender}
  147 + ${biddingresponce}= Call Method ${USERS.users['${ARGUMENTS[0]}'].client} create_question ${tender} ${ARGUMENTS[2]}
  148 + [return] ${biddingresponce}
  149 +
144 Відповісти на питання 150 Відповісти на питання
145 [Documentation] 151 [Documentation]
146 ... ${ARGUMENTS[0]} == username 152 ... ${ARGUMENTS[0]} == username
@@ -167,7 +173,24 @@ ${question_id} 0 @@ -167,7 +173,24 @@ ${question_id} 0
167 ${tender}= Call Method ${USERS.users['${ARGUMENTS[0]}'].client} get_tender ${ARGUMENTS[1]} 173 ${tender}= Call Method ${USERS.users['${ARGUMENTS[0]}'].client} get_tender ${ARGUMENTS[1]}
168 ${complaint}= Call Method ${USERS.users['${ARGUMENTS[0]}'].client} _create_tender_resource_item ${tender} ${ARGUMENTS[2]} complaints 174 ${complaint}= Call Method ${USERS.users['${ARGUMENTS[0]}'].client} _create_tender_resource_item ${tender} ${ARGUMENTS[2]} complaints
169 Log object data ${complaint} complaint 175 Log object data ${complaint} complaint
170 - 176 +
  177 +порівняти скаргу
  178 + [Documentation]
  179 + ... ${ARGUMENTS[0]} == username
  180 + ... ${ARGUMENTS[1]} == tender_uid
  181 + ... ${ARGUMENTS[2]} == complaint
  182 + [Arguments] @{ARGUMENTS}
  183 + ${tender}= Call Method ${USERS.users['${ARGUMENTS[0]}'].client} get_tender ${ARGUMENTS[1]}
  184 + ${complaint}= Get Variable Value ${tender.data.complaints[0]}
  185 + log ${complaint}
  186 + log ${ARGUMENTS[2]}
  187 + #TODO: COMPARE
  188 + #Dictionary Should Contain Sub Dictionary ${complaint} ${ARGUMENTS[2].data}
  189 + #:FOR ${element} IN ${ARGUMENTS[2].data}
  190 + #\ log ${element}
  191 + #\ Dictionary Should Contain Value ${complaint} ${element}
  192 +
  193 +
171 Обробити скаргу 194 Обробити скаргу
172 [Documentation] 195 [Documentation]
173 ... ${ARGUMENTS[0]} == username 196 ... ${ARGUMENTS[0]} == username
@@ -182,6 +205,8 @@ ${question_id} 0 @@ -182,6 +205,8 @@ ${question_id} 0
182 ${complaint_with_answer}= Call Method ${USERS.users['${ARGUMENTS[0]}'].client} _patch_tender_resource_item ${tender} ${ARGUMENTS[3]} complaints 205 ${complaint_with_answer}= Call Method ${USERS.users['${ARGUMENTS[0]}'].client} _patch_tender_resource_item ${tender} ${ARGUMENTS[3]} complaints
183 log many ${USERS.users['${ARGUMENTS[0]}'].client} ${tender} ${ARGUMENTS[3]} 206 log many ${USERS.users['${ARGUMENTS[0]}'].client} ${tender} ${ARGUMENTS[3]}
184 Log object data ${complaint_with_answer} complaint_with_answer 207 Log object data ${complaint_with_answer} complaint_with_answer
  208 +
  209 +
185 210
186 Подати цінову пропозицію 211 Подати цінову пропозицію
187 [Documentation] 212 [Documentation]
@@ -191,6 +216,7 @@ ${question_id} 0 @@ -191,6 +216,7 @@ ${question_id} 0
191 [Arguments] @{ARGUMENTS} 216 [Arguments] @{ARGUMENTS}
192 log many @{ARGUMENTS} 217 log many @{ARGUMENTS}
193 ${tender}= Call Method ${USERS.users['${ARGUMENTS[0]}'].client} get_tender ${ARGUMENTS[1]} 218 ${tender}= Call Method ${USERS.users['${ARGUMENTS[0]}'].client} get_tender ${ARGUMENTS[1]}
  219 + log ${tender}
194 ${biddingresponce}= Call Method ${USERS.users['${ARGUMENTS[0]}'].client} create_bid ${tender} ${ARGUMENTS[2]} 220 ${biddingresponce}= Call Method ${USERS.users['${ARGUMENTS[0]}'].client} create_bid ${tender} ${ARGUMENTS[2]}
195 [return] ${biddingresponce} 221 [return] ${biddingresponce}
196 222
@@ -218,6 +244,21 @@ ${question_id} 0 @@ -218,6 +244,21 @@ ${question_id} 0
218 [return] ${award_activeted_response} 244 [return] ${award_activeted_response}
219 245
220 246
  247 +Завантажити документ в ставку
  248 + [Documentation]
  249 + ... ${ARGUMENTS[0]} == username
  250 + ... ${ARGUMENTS[1]} == token
  251 + ... ${ARGUMENTS[2]} == bid_id
  252 + [Arguments] @{ARGUMENTS}
  253 + log ${ARGUMENTS[0]}
  254 + log ${ARGUMENTS[1]}
  255 + ${tender}= Call Method ${USERS.users['${ARGUMENTS[0]}'].client} get_tender ${TENDER_DATA.data.id}
  256 + ${tender}= set_access_key ${tender} ${ARGUMENTS[1]}
  257 + ${filename}= Set Variable file.txt
  258 + Set_To_Object ${TENDER_DATA.data} documents.title ${filename}
  259 + ${reply}= Call Method ${USERS.users['${ARGUMENTS[0]}'].client} upload_bid_document ${filename} ${tender} ${ARGUMENTS[2]}
  260 + Log object data ${reply} reply
  261 +
221 Завантажити документ 262 Завантажити документ
222 [Documentation] 263 [Documentation]
223 ... ${ARGUMENTS[0]} == username 264 ... ${ARGUMENTS[0]} == username
@@ -227,7 +268,8 @@ ${question_id} 0 @@ -227,7 +268,8 @@ ${question_id} 0
227 log ${ARGUMENTS[1]} 268 log ${ARGUMENTS[1]}
228 ${tender}= Call Method ${USERS.users['${ARGUMENTS[0]}'].client} get_tender ${TENDER_DATA.data.id} 269 ${tender}= Call Method ${USERS.users['${ARGUMENTS[0]}'].client} get_tender ${TENDER_DATA.data.id}
229 ${tender}= set_access_key ${tender} ${ARGUMENTS[1]} 270 ${tender}= set_access_key ${tender} ${ARGUMENTS[1]}
230 - ${reply}= Call Method ${USERS.users['${ARGUMENTS[0]}'].client} upload_tender_document ${tender} 271 + ${filename}= Set Variable file.txt
  272 + Set_To_Object ${TENDER_DATA.data} documents.title ${filename}
  273 + ${reply}= Call Method ${USERS.users['${ARGUMENTS[0]}'].client} upload_tender_document ${filename} ${tender}
231 Log object data ${reply} reply 274 Log object data ${reply} reply
232 -  
233   275  
Please register or login to post a comment