Commit 5201682d701db9db22ee76028c356ba1f4151787

Authored by yboi
1 parent e487beb4

створення_тендеру_і_багатопредметного_тендеру_etendet+netcast

... ... @@ -31,6 +31,7 @@ ${locator.enquiryPeriod.endDate} jquery=tender-procedure-info>div.row:contai
31 31 # login
32 32 Wait Until Page Contains Element id=inputUsername 100
33 33 Input text id=inputUsername ${USERS.users['${username}'].login}
  34 + Wait Until Page Contains Element id=inputPassword 100
34 35 Input text id=inputPassword ${USERS.users['${username}'].password}
35 36 Click Button id=btn_submit
36 37
... ... @@ -48,6 +49,7 @@ ${locator.enquiryPeriod.endDate} jquery=tender-procedure-info>div.row:contai
48 49 ${items_description}= Get From Dictionary ${ARGUMENTS[1].data} description
49 50 ${quantity}= Get From Dictionary ${items[0]} quantity
50 51 ${cpv}= Get From Dictionary ${items[0].classification} id
  52 + ${cpv_id}= Get From Dictionary ${items[0].classification} id
51 53 ${dkpp_desc}= Get From Dictionary ${items[0].additionalClassifications[0]} description
52 54 ${dkpp_id}= Get From Dictionary ${items[0].additionalClassifications[0]} id
53 55 ${unit}= Get From Dictionary ${items[0].unit} name
... ... @@ -80,34 +82,32 @@ ${locator.enquiryPeriod.endDate} jquery=tender-procedure-info>div.row:contai
80 82 Click Element xpath=//select[@name="itemsUnit"]/option[@value='kilogram']
81 83 Input text xpath=//div[contains(@class, 'form-group col-sm-8')]//input[@name='enqPEndDate'] ${enquiry_end_date}
82 84 Input text xpath=//div[contains(@class, 'form-group col-sm-8')]//div[contains(@class, 'col-sm-2')]//input[@ng-model='data.enquiryPeriod.endDate'] ${enquiry_end_time}
83   -
84 85 Input text xpath=//div[contains(@class, 'form-group col-sm-8')]//input[@name='startDate'] ${start_date}
85 86 Input text xpath=//div[contains(@class, 'form-group col-sm-8')]//div[contains(@class, 'col-sm-2')]//input[@ng-model='data.tenderPeriod.startDate'] ${start_time}
86 87 Input text xpath=//div[contains(@class, 'form-group col-sm-8')]//input[@name='endDate'] ${end_date}
87 88 Input text xpath=//div[contains(@class, 'form-group col-sm-8')]//div[contains(@class, 'col-sm-2')]//input[@ng-model='data.tenderPeriod.endDate'] ${end_time}
88   -
89 89 Click Element xpath=//div[contains(@class, 'col-sm-2')]//input[@data-target='#classification']
90   - Wait Until Page Contains Оберіть класифікатор CPV 100
91   - Input text xpath=//div[contains(@class, 'modal-content')]//input[@ng-model='searchstring'] ${cpv}
92   - Wait Until Page Contains Картонки 100
93   - Click Element xpath=//table[contains(@class, 'table table-hover table-striped table-bordered ng-table-rowselected ng-scope ng-table')]//tr[1]//td[1]
94   - Wait Until Page Contains 44617100-9 Картонки 100
  90 + Wait Until Element Is Visible xpath=//div[contains(@role,'dialog')]
  91 + Input text xpath=//div[contains(@class, 'modal-content')]//input[@ng-model='searchstring'] ${cpv}
  92 + Wait Until Page Contains ${cpv}
  93 + Click Element xpath=//td[contains(., '${cpv}')]
95 94 Click Element xpath=//div[contains(@class, 'modal-content')]//button[@ng-click='choose()']
96   -
97 95 Click Element xpath=//div[contains(@class, 'col-sm-2')]//input[@data-target='#addClassification']
98   - Wait Until Page Contains Класифікатор ДКПП 100
  96 + Wait Until Element Is Visible xpath=//div[contains(@id,'addClassification')]
99 97 Input text xpath=//div[contains(@class, 'modal fade ng-scope in')]//input[@ng-model='searchstring'] ${dkpp_desc}
100   - Wait Until Page Contains ${dkpp_id} 100
101   - Click Element xpath=//table[contains(@class, 'table table-hover table-striped table-bordered ng-table-rowselected ng-scope ng-table')]//tr[2]//td[1]
102   - Wait Until Page Contains 17.21.1 "Папір і картон гофровані, паперова й картонна тара" 100
  98 + Wait Until Page Contains ${dkpp_id}
  99 + Click Element xpath=//td[contains(., '${dkpp_id}')]
103 100 Click Element xpath=//div[contains(@class, 'modal fade ng-scope in')]//button[@ng-click='choose()']
  101 + Run Keyword if '${mode}' == 'multi' Додати предмет items
  102 + Wait Until Page Contains Element xpath=//div[contains(@class, 'form-actions')]//button[@type='submit']
104 103 Click Element xpath=//div[contains(@class, 'form-actions')]//button[@type='submit']
105 104 Wait Until Page Contains [ТЕСТУВАННЯ] 100
106 105 Click Element xpath=//table[contains(@class, 'table table-hover table-striped table-bordered ng-scope ng-table')]//tr[1]//a
107 106 ${tender_UAid}= Wait Until Keyword Succeeds 240sec 2sec get tender UAid
108 107 ### harcode Idis bacause issues on the E-tender side, to remove, 1 line:
109 108 ${tender_UAid}= Convert To String UA-2015-06-30-000012
110   - ${Ids} Create List ${tender_UAid}
  109 + ${id}= Oтримати internal id по UAid ${ARGUMENTS[0]} ${tender_UAid}
  110 + ${Ids} Create List ${tender_UAid} ${id}
111 111 [return] ${Ids}
112 112
113 113 get tender UAid
... ... @@ -128,6 +128,53 @@ Oтримати internal id по UAid
128 128 log ${tender_id}
129 129 [return] ${tender_id}
130 130
  131 +Додати предмет
  132 + [Arguments] @{ARGUMENTS}
  133 + [Documentation]
  134 + ... ${ARGUMENTS[0]} == items
  135 + ${dkpp_desc1}= Get From Dictionary ${items[1].additionalClassifications[0]} description
  136 + ${dkpp_id1}= Get From Dictionary ${items[1].additionalClassifications[0]} id
  137 + ${dkpp_desc2}= Get From Dictionary ${items[2].additionalClassifications[0]} description
  138 + ${dkpp_id2}= Get From Dictionary ${items[2].additionalClassifications[0]} id
  139 + ${dkpp_desc3}= Get From Dictionary ${items[3].additionalClassifications[0]} description
  140 + ${dkpp_id3}= Get From Dictionary ${items[3].additionalClassifications[0]} id
  141 +
  142 + Wait Until Page Contains Element xpath=.//*[@id='myform']/tender-form/div/button 100
  143 + Click Element xpath=.//*[@id='myform']/tender-form/div/button
  144 + Sleep 2
  145 + Wait Until Page Contains Element xpath=(//div[contains(@class, 'col-sm-2')]//input[@data-target='#addClassification'])[2] 100
  146 + Click Element xpath=(//div[contains(@class, 'col-sm-2')]//input[@data-target='#addClassification'])[2]
  147 + Wait Until Element Is Visible xpath=//div[contains(@id,'addClassification')]
  148 + Input text xpath=//div[contains(@class, 'modal fade ng-scope in')]//input[@ng-model='searchstring'] ${dkpp_desc1}
  149 + Wait Until Page Contains ${dkpp_id1}
  150 + Click Element xpath=//td[contains(., '${dkpp_id1}')]
  151 + Click Element xpath=//div[contains(@class, 'modal fade ng-scope in')]//button[@ng-click='choose()']
  152 +
  153 + Sleep 2
  154 + Wait Until Page Contains Element xpath=.//*[@id='myform']/tender-form/div/button 100
  155 + Click Element xpath=.//*[@id='myform']/tender-form/div/button
  156 + Sleep 2
  157 + Wait Until Page Contains Element xpath=(//div[contains(@class, 'col-sm-2')]//input[@data-target='#addClassification'])[3] 100
  158 + Click Element xpath=(//div[contains(@class, 'col-sm-2')]//input[@data-target='#addClassification'])[3]
  159 + Wait Until Element Is Visible xpath=//div[contains(@id,'addClassification')]
  160 + Input text xpath=//div[contains(@class, 'modal fade ng-scope in')]//input[@ng-model='searchstring'] ${dkpp_desc2}
  161 + Wait Until Page Contains ${dkpp_id2}
  162 + Click Element xpath=//td[contains(., '${dkpp_id2}')]
  163 + Click Element xpath=//div[contains(@class, 'modal fade ng-scope in')]//button[@ng-click='choose()']
  164 +
  165 + Sleep 2
  166 + Wait Until Page Contains Element xpath=.//*[@id='myform']/tender-form/div/button 100
  167 + Click Element xpath=.//*[@id='myform']/tender-form/div/button
  168 + Sleep 2
  169 + Wait Until Page Contains Element xpath=(//div[contains(@class, 'col-sm-2')]//input[@data-target='#addClassification'])[4] 100
  170 + Click Element xpath=(//div[contains(@class, 'col-sm-2')]//input[@data-target='#addClassification'])[4]
  171 + Wait Until Element Is Visible xpath=//div[contains(@id,'addClassification')]
  172 + Input text xpath=//div[contains(@class, 'modal fade ng-scope in')]//input[@ng-model='searchstring'] ${dkpp_desc3}
  173 + Wait Until Page Contains ${dkpp_id3}
  174 + Click Element xpath=//td[contains(., '${dkpp_id3}')]
  175 + Click Element xpath=//div[contains(@class, 'modal fade ng-scope in')]//button[@ng-click='choose()']
  176 +
  177 +
131 178 Пошук тендера по ідентифікатору
132 179 [Arguments] @{ARGUMENTS}
133 180 [Documentation]
... ... @@ -330,127 +377,4 @@ Oтримати internal id по UAid
330 377
331 378 Click Element xpath=//div[div/pre[1]]/div[1]
332 379 Input text xpath=//div[textarea]/textarea ${answer}
333   - Click Element xpath=//div[textarea]/span/button[1]
334   -
335   -Багатопредметний тендер
336   - [Arguments] @{ARGUMENTS}
337   - [Documentation]
338   - ... ${ARGUMENTS[0]} == username
339   - ... ${ARGUMENTS[1]} == tender_data
340   -
341   - ${items}= Get From Dictionary ${ARGUMENTS[1].data} items
342   - ${title}= Get From Dictionary ${ARGUMENTS[1].data} title
343   - ${description}= Get From Dictionary ${ARGUMENTS[1].data} description
344   - ${budget}= Get From Dictionary ${ARGUMENTS[1].data.value} amount
345   - ${step_rate}= Get From Dictionary ${ARGUMENTS[1].data.minimalStep} amount
346   - ${items_description}= Get From Dictionary ${ARGUMENTS[1].data} description
347   - ${quantity}= Get From Dictionary ${items[0]} quantity
348   - ${cpv}= Get From Dictionary ${items[0].classification} id
349   - ${dkpp_desc0}= Get From Dictionary ${items[0].additionalClassifications[0]} description
350   - ${dkpp_id0}= Get From Dictionary ${items[0].additionalClassifications[0]} id
351   - ${dkpp_desc1}= Get From Dictionary ${items[1].additionalClassifications[0]} description
352   - ${dkpp_id1}= Get From Dictionary ${items[1].additionalClassifications[0]} id
353   - ${dkpp_desc2}= Get From Dictionary ${items[2].additionalClassifications[0]} description
354   - ${dkpp_id2}= Get From Dictionary ${items[2].additionalClassifications[0]} id
355   - ${dkpp_desc3}= Get From Dictionary ${items[3].additionalClassifications[0]} description
356   - ${dkpp_id3}= Get From Dictionary ${items[3].additionalClassifications[0]} id
357   - ${unit}= Get From Dictionary ${items[0].unit} name
358   - ${start_date}= Get From Dictionary ${ARGUMENTS[1].data.tenderPeriod} startDate
359   - ${start_date}= convert_date_to_etender_format ${start_date}
360   - ${start_time}= Get From Dictionary ${ARGUMENTS[1].data.tenderPeriod} startDate
361   - ${start_time}= convert_time_to_etender_format ${start_time}
362   - ${end_date}= Get From Dictionary ${ARGUMENTS[1].data.tenderPeriod} endDate
363   - ${end_date}= convert_date_to_etender_format ${end_date}
364   - ${end_time}= Get From Dictionary ${ARGUMENTS[1].data.tenderPeriod} endDate
365   - ${end_time}= convert_time_to_etender_format ${end_time}
366   - ${enquiry_end_date}= Get From Dictionary ${ARGUMENTS[1].data.enquiryPeriod} endDate
367   - ${enquiry_end_date}= convert_date_to_etender_format ${enquiry_end_date}
368   - ${enquiry_end_time}= Get From Dictionary ${ARGUMENTS[1].data.enquiryPeriod} endDate
369   - ${enquiry_end_time}= convert_time_to_etender_format ${enquiry_end_time}
370   -
371   - Selenium2Library.Switch Browser ${ARGUMENTS[0]}
372   - Maximize Browser Window
373   - Wait Until Page Contains Мої закупівлі 100
374   - Click Element xpath=//a[contains(@class, 'ng-binding')][./text()='Мої закупівлі']
375   - Wait Until Page Contains Element xpath=//a[contains(@class, 'btn btn-info')] 100
376   - Click Element xpath=//a[contains(@class, 'btn btn-info')]
377   - Wait Until Page Contains Element id=title
378   - Input text id=title ${title}
379   - Input text id=description ${description}
380   - Input text id=value ${budget}
381   - Click Element xpath=//div[contains(@class, 'form-group col-sm-6')]//input[@type='checkbox']
382   - Input text id=minimalStep ${step_rate}
383   - Input text id=itemsDescription ${items_description}
384   - DEBUG
385   - Input text id=itemsQuantity ${quantity}
386   - Click Element xpath=//select[@name="itemsUnit"]/option[@value='kilogram']
387   - Input text xpath=//div[contains(@class, 'form-group col-sm-8')]//input[@name='enqPEndDate'] ${enquiry_end_date}
388   - Input text xpath=//div[contains(@class, 'form-group col-sm-8')]//div[contains(@class, 'col-sm-2')]//input[@ng-model='data.enquiryPeriod.endDate'] ${enquiry_end_time}
389   -
390   - Input text xpath=//div[contains(@class, 'form-group col-sm-8')]//input[@name='startDate'] ${start_date}
391   - Input text xpath=//div[contains(@class, 'form-group col-sm-8')]//div[contains(@class, 'col-sm-2')]//input[@ng-model='data.tenderPeriod.startDate'] ${start_time}
392   - Input text xpath=//div[contains(@class, 'form-group col-sm-8')]//input[@name='endDate'] ${end_date}
393   - Input text xpath=//div[contains(@class, 'form-group col-sm-8')]//div[contains(@class, 'col-sm-2')]//input[@ng-model='data.tenderPeriod.endDate'] ${end_time}
394   -
395   - Click Element xpath=//div[contains(@class, 'col-sm-2')]//input[@data-target='#classification']
396   - Wait Until Page Contains Element xpath=//div[contains(@class, 'modal-content')]//input[@ng-model='searchstring'] 100
397   - Input text xpath=//div[contains(@class, 'modal-content')]//input[@ng-model='searchstring'] ${cpv}
398   - Wait Until Page Contains Картонки 100
399   - Click Element xpath=//table[contains(@class, 'table table-hover table-striped table-bordered ng-table-rowselected ng-scope ng-table')]//tr[1]//td[1]
400   - Wait Until Page Contains 44617100-9 Картонки 100
401   - Click Element xpath=//div[contains(@class, 'modal-content')]//button[@ng-click='choose()']
402   -
403   - Wait Until Page Contains Element xpath=//div[contains(@class, 'col-sm-2')]//input[@data-target='#addClassification'] 100
404   - Click Element xpath=//div[contains(@class, 'col-sm-2')]//input[@data-target='#addClassification']
405   - Wait Until Page Contains Element xpath=//div[contains(@class, 'modal fade ng-scope in')]//input[@ng-model='searchstring'] 100
406   - Input text xpath=//div[contains(@class, 'modal fade ng-scope in')]//input[@ng-model='searchstring'] ${dkpp_desc0}
407   - Wait Until Page Contains ${dkpp_id0} 100
408   - Click Element xpath=//table[contains(@class, 'table table-hover table-striped table-bordered ng-table-rowselected ng-scope ng-table')]//tr[2]//td[1]
409   - Wait Until Page Contains 17.29.12-00.00 "Блоки, плити та пластини фільтрувальні, з паперової маси" 100
410   - Click Element xpath=//div[contains(@class, 'modal fade ng-scope in')]//button[@ng-click='choose()']
411   -
412   - Wait Until Page Contains Element xpath=.//*[@id='myform']/tender-form/div/button 100
413   - Click Element xpath=.//*[@id='myform']/tender-form/div/button
414   - Sleep 2
415   - Click Element xpath=(//div[contains(@class, 'col-sm-2')]//input[@data-target='#addClassification'])[2]
416   - Wait Until Page Contains Element xpath=//div[contains(@class, 'modal fade ng-scope in')]//input[@ng-model='searchstring'] 100
417   - Input text xpath=//div[contains(@class, 'modal fade ng-scope in')]//input[@ng-model='searchstring'] ${dkpp_desc1}
418   - Wait Until Page Contains ${dkpp_id1} 100
419   - Click Element xpath=//table[contains(@class, 'table table-hover table-striped table-bordered ng-table-rowselected ng-scope ng-table')]//tr[3]//td[1]
420   - Wait Until Page Contains 17.21.99-00.00 "Роботи субпідрядні як частина виробництва гофрованих паперу й картону, паперової та картонної тари" 100
421   - Click Element xpath=//div[contains(@class, 'modal fade ng-scope in')]//button[@ng-click='choose()']
422   -
423   - Wait Until Page Contains Element xpath=.//*[@id='myform']/tender-form/div/button 100
424   - Click Element xpath=.//*[@id='myform']/tender-form/div/button
425   - Sleep 2
426   - Click Element xpath=(//div[contains(@class, 'col-sm-2')]//input[@data-target='#addClassification'])[3]
427   - Wait Until Page Contains Element xpath=//div[contains(@class, 'modal fade ng-scope in')]//input[@ng-model='searchstring'] 100
428   - Input text xpath=//div[contains(@class, 'modal fade ng-scope in')]//input[@ng-model='searchstring'] ${dkpp_desc2}
429   - Wait Until Page Contains ${dkpp_id2} 100
430   - Click Element xpath=.//*[@id='addClassification']/div/div/div[2]/table/tbody/tr/td[2]
431   - Wait Until Page Contains 17.22.12-40.00 "Вата; вироби з вати, інші" 100
432   - Click Element xpath=//div[contains(@class, 'modal fade ng-scope in')]//button[@ng-click='choose()']
433   -
434   - Sleep 2
435   - Wait Until Page Contains Element xpath=.//*[@id='myform']/tender-form/div/button 100
436   - Click Element xpath=.//*[@id='myform']/tender-form/div/button
437   - Wait Until Page Contains Element xpath=(//div[contains(@class, 'col-sm-2')]//input[@data-target='#addClassification'])[4] 100
438   - Click Element xpath=(//div[contains(@class, 'col-sm-2')]//input[@data-target='#addClassification'])[4]
439   - Wait Until Page Contains Element xpath=//div[contains(@class, 'modal fade ng-scope in')]//input[@ng-model='searchstring'] 100
440   - Input text xpath=//div[contains(@class, 'modal fade ng-scope in')]//input[@ng-model='searchstring'] ${dkpp_desc3}
441   - Wait Until Page Contains ${dkpp_id3} 100
442   - Click Element xpath=.//*[@id='addClassification']/div/div/div[2]/table/tbody/tr/td[2]
443   - Wait Until Page Contains 17.22.12-50.00 "Одяг і речі до одягу з паперової маси, паперу, целюлозної вати чи полотна з целюлозного волокна (крім носових хусточок, наголовних уборів)" 100
444   - Click Element xpath=//div[contains(@class, 'modal fade ng-scope in')]//button[@ng-click='choose()']
445   -
446   - Wait Until Page Contains Element xpath=//div[contains(@class, 'form-actions')]//button[@type='submit']
447   - Capture Page Screenshot
448   - Click Element xpath=//div[contains(@class, 'form-actions')]//button[@type='submit']
449   - Wait Until Page Contains [ТЕСТУВАННЯ] 100
450   - Click Element xpath=//table[contains(@class, 'table table-hover table-striped table-bordered ng-scope ng-table')]//tr[1]//a
451   - ${tender_UAid}= Wait Until Keyword Succeeds 240sec 2sec get tender UAid
452   -### harcode Idis bacause issues on the E-tender side, to remove, 1 line:
453   - ${tender_UAid}= Convert To String UA-2015-06-30-000012
454   - ${id}= Oтримати internal id по UAid ${ARGUMENTS[0]} ${tender_UAid}
455   - ${Ids} Create List ${tender_UAid} ${id}
456   - [return] ${Ids}
  380 + Click Element xpath=//div[textarea]/span/button[1]
\ No newline at end of file
... ...
... ... @@ -19,7 +19,7 @@ users:
19 19 password: Password1
20 20 browser: firefox
21 21 position: [0, 0]
22   - size: [640, 450]
  22 + size: [740, 550]
23 23 E-tender_Provider1:
24 24 broker: E-tender
25 25 username: E-tendertest
... ...
Please register or login to post a comment