Commit 7203b85fa0f2a6d956167127111173c97bce89cd
Committed by
GitHub
Merge pull request #143 from ProzorroUKR/plan_tender
plan tender for monitorings and validations
Showing
4 changed files
with
26 additions
and
8 deletions
@@ -68,6 +68,9 @@ ${ERROR_MESSAGE}= Calling method 'get_tender' failed: ResourceGone: {"status": | @@ -68,6 +68,9 @@ ${ERROR_MESSAGE}= Calling method 'get_tender' failed: ResourceGone: {"status": | ||
68 | 68 | ||
69 | 69 | ||
70 | Можливість оголосити тендер з використанням валідації для MNN | 70 | Можливість оголосити тендер з використанням валідації для MNN |
71 | + ${file_path}= Get Variable Value ${ARTIFACT_FILE} artifact.yaml | ||
72 | + ${ARTIFACT}= load_data_from ${file_path} | ||
73 | + Log ${ARTIFACT.tender_uaid} | ||
71 | [Arguments] ${data_version} | 74 | [Arguments] ${data_version} |
72 | ${NUMBER_OF_LOTS}= Convert To Integer ${NUMBER_OF_LOTS} | 75 | ${NUMBER_OF_LOTS}= Convert To Integer ${NUMBER_OF_LOTS} |
73 | ${NUMBER_OF_ITEMS}= Convert To Integer ${NUMBER_OF_ITEMS} | 76 | ${NUMBER_OF_ITEMS}= Convert To Integer ${NUMBER_OF_ITEMS} |
@@ -84,11 +87,14 @@ ${ERROR_MESSAGE}= Calling method 'get_tender' failed: ResourceGone: {"status": | @@ -84,11 +87,14 @@ ${ERROR_MESSAGE}= Calling method 'get_tender' failed: ResourceGone: {"status": | ||
84 | ... moz_integration=${${MOZ_INTEGRATION}} | 87 | ... moz_integration=${${MOZ_INTEGRATION}} |
85 | ... road_index=${${ROAD_INDEX}} | 88 | ... road_index=${${ROAD_INDEX}} |
86 | ... gmdn_index=${${GMDN_INDEX}} | 89 | ... gmdn_index=${${GMDN_INDEX}} |
90 | + ... plan_tender=${${PLAN_TENDER}} | ||
87 | ${DIALOGUE_TYPE}= Get Variable Value ${DIALOGUE_TYPE} | 91 | ${DIALOGUE_TYPE}= Get Variable Value ${DIALOGUE_TYPE} |
88 | ${FUNDING_KIND}= Get Variable Value ${FUNDING_KIND} | 92 | ${FUNDING_KIND}= Get Variable Value ${FUNDING_KIND} |
89 | Run keyword if '${DIALOGUE_TYPE}' != '${None}' Set to dictionary ${tender_parameters} dialogue_type=${DIALOGUE_TYPE} | 93 | Run keyword if '${DIALOGUE_TYPE}' != '${None}' Set to dictionary ${tender_parameters} dialogue_type=${DIALOGUE_TYPE} |
90 | Run keyword if '${FUNDING_KIND}' != '${None}' Set to dictionary ${tender_parameters} fundingKind=${FUNDING_KIND} | 94 | Run keyword if '${FUNDING_KIND}' != '${None}' Set to dictionary ${tender_parameters} fundingKind=${FUNDING_KIND} |
91 | - ${tender_data}= Підготувати дані для створення тендера ${tender_parameters} | 95 | + ${plan_data}= Run as ${tender_owner} Пошук плану по ідентифікатору ${ARTIFACT.tender_uaid} |
96 | + Log ${plan_data} | ||
97 | + ${tender_data}= Підготувати дані для створення тендера ${tender_parameters} ${plan_data} | ||
92 | ${adapted_data}= Адаптувати дані для оголошення тендера ${tender_data} | 98 | ${adapted_data}= Адаптувати дані для оголошення тендера ${tender_data} |
93 | ${adapted_data_mnn}= edit_tender_data_for_mnn ${adapted_data} ${MODE} ${data_version} | 99 | ${adapted_data_mnn}= edit_tender_data_for_mnn ${adapted_data} ${MODE} ${data_version} |
94 | Log ${adapted_data_mnn} | 100 | Log ${adapted_data_mnn} |
@@ -99,6 +105,9 @@ ${ERROR_MESSAGE}= Calling method 'get_tender' failed: ResourceGone: {"status": | @@ -99,6 +105,9 @@ ${ERROR_MESSAGE}= Calling method 'get_tender' failed: ResourceGone: {"status": | ||
99 | 105 | ||
100 | Можливість оголосити тендер з використанням валідації Індекс автомобільних доріг | 106 | Можливість оголосити тендер з використанням валідації Індекс автомобільних доріг |
101 | [Arguments] ${data_version} | 107 | [Arguments] ${data_version} |
108 | + ${file_path}= Get Variable Value ${ARTIFACT_FILE} artifact.yaml | ||
109 | + ${ARTIFACT}= load_data_from ${file_path} | ||
110 | + Log ${ARTIFACT.tender_uaid} | ||
102 | ${NUMBER_OF_LOTS}= Convert To Integer ${NUMBER_OF_LOTS} | 111 | ${NUMBER_OF_LOTS}= Convert To Integer ${NUMBER_OF_LOTS} |
103 | ${NUMBER_OF_ITEMS}= Convert To Integer ${NUMBER_OF_ITEMS} | 112 | ${NUMBER_OF_ITEMS}= Convert To Integer ${NUMBER_OF_ITEMS} |
104 | ${NUMBER_OF_MILESTONES}= Convert To Integer ${NUMBER_OF_MILESTONES} | 113 | ${NUMBER_OF_MILESTONES}= Convert To Integer ${NUMBER_OF_MILESTONES} |
@@ -114,11 +123,14 @@ ${ERROR_MESSAGE}= Calling method 'get_tender' failed: ResourceGone: {"status": | @@ -114,11 +123,14 @@ ${ERROR_MESSAGE}= Calling method 'get_tender' failed: ResourceGone: {"status": | ||
114 | ... moz_integration=${${MOZ_INTEGRATION}} | 123 | ... moz_integration=${${MOZ_INTEGRATION}} |
115 | ... road_index=${${ROAD_INDEX}} | 124 | ... road_index=${${ROAD_INDEX}} |
116 | ... gmdn_index=${${GMDN_INDEX}} | 125 | ... gmdn_index=${${GMDN_INDEX}} |
126 | + ... plan_tender=${${PLAN_TENDER}} | ||
117 | ${DIALOGUE_TYPE}= Get Variable Value ${DIALOGUE_TYPE} | 127 | ${DIALOGUE_TYPE}= Get Variable Value ${DIALOGUE_TYPE} |
118 | ${FUNDING_KIND}= Get Variable Value ${FUNDING_KIND} | 128 | ${FUNDING_KIND}= Get Variable Value ${FUNDING_KIND} |
119 | Run keyword if '${DIALOGUE_TYPE}' != '${None}' Set to dictionary ${tender_parameters} dialogue_type=${DIALOGUE_TYPE} | 129 | Run keyword if '${DIALOGUE_TYPE}' != '${None}' Set to dictionary ${tender_parameters} dialogue_type=${DIALOGUE_TYPE} |
120 | Run keyword if '${FUNDING_KIND}' != '${None}' Set to dictionary ${tender_parameters} fundingKind=${FUNDING_KIND} | 130 | Run keyword if '${FUNDING_KIND}' != '${None}' Set to dictionary ${tender_parameters} fundingKind=${FUNDING_KIND} |
121 | - ${tender_data}= Підготувати дані для створення тендера ${tender_parameters} | 131 | + ${plan_data}= Run as ${tender_owner} Пошук плану по ідентифікатору ${ARTIFACT.tender_uaid} |
132 | + Log ${plan_data} | ||
133 | + ${tender_data}= Підготувати дані для створення тендера ${tender_parameters} ${plan_data} | ||
122 | ${adapted_data}= Адаптувати дані для оголошення тендера ${tender_data} | 134 | ${adapted_data}= Адаптувати дані для оголошення тендера ${tender_data} |
123 | ${adapted_data_cost}= edit_tender_data_for_cost ${adapted_data} ${MODE} ${data_version} | 135 | ${adapted_data_cost}= edit_tender_data_for_cost ${adapted_data} ${MODE} ${data_version} |
124 | Log ${adapted_data_cost} | 136 | Log ${adapted_data_cost} |
@@ -129,6 +141,9 @@ ${ERROR_MESSAGE}= Calling method 'get_tender' failed: ResourceGone: {"status": | @@ -129,6 +141,9 @@ ${ERROR_MESSAGE}= Calling method 'get_tender' failed: ResourceGone: {"status": | ||
129 | 141 | ||
130 | Можливість оголосити тендер з використанням валідації класифікатор медичних виробів | 142 | Можливість оголосити тендер з використанням валідації класифікатор медичних виробів |
131 | [Arguments] ${data_version} | 143 | [Arguments] ${data_version} |
144 | + ${file_path}= Get Variable Value ${ARTIFACT_FILE} artifact.yaml | ||
145 | + ${ARTIFACT}= load_data_from ${file_path} | ||
146 | + Log ${ARTIFACT.tender_uaid} | ||
132 | ${NUMBER_OF_LOTS}= Convert To Integer ${NUMBER_OF_LOTS} | 147 | ${NUMBER_OF_LOTS}= Convert To Integer ${NUMBER_OF_LOTS} |
133 | ${NUMBER_OF_ITEMS}= Convert To Integer ${NUMBER_OF_ITEMS} | 148 | ${NUMBER_OF_ITEMS}= Convert To Integer ${NUMBER_OF_ITEMS} |
134 | ${NUMBER_OF_MILESTONES}= Convert To Integer ${NUMBER_OF_MILESTONES} | 149 | ${NUMBER_OF_MILESTONES}= Convert To Integer ${NUMBER_OF_MILESTONES} |
@@ -144,11 +159,14 @@ ${ERROR_MESSAGE}= Calling method 'get_tender' failed: ResourceGone: {"status": | @@ -144,11 +159,14 @@ ${ERROR_MESSAGE}= Calling method 'get_tender' failed: ResourceGone: {"status": | ||
144 | ... moz_integration=${${MOZ_INTEGRATION}} | 159 | ... moz_integration=${${MOZ_INTEGRATION}} |
145 | ... road_index=${${ROAD_INDEX}} | 160 | ... road_index=${${ROAD_INDEX}} |
146 | ... gmdn_index=${${GMDN_INDEX}} | 161 | ... gmdn_index=${${GMDN_INDEX}} |
162 | + ... plan_tender=${${PLAN_TENDER}} | ||
147 | ${DIALOGUE_TYPE}= Get Variable Value ${DIALOGUE_TYPE} | 163 | ${DIALOGUE_TYPE}= Get Variable Value ${DIALOGUE_TYPE} |
148 | ${FUNDING_KIND}= Get Variable Value ${FUNDING_KIND} | 164 | ${FUNDING_KIND}= Get Variable Value ${FUNDING_KIND} |
149 | Run keyword if '${DIALOGUE_TYPE}' != '${None}' Set to dictionary ${tender_parameters} dialogue_type=${DIALOGUE_TYPE} | 165 | Run keyword if '${DIALOGUE_TYPE}' != '${None}' Set to dictionary ${tender_parameters} dialogue_type=${DIALOGUE_TYPE} |
150 | Run keyword if '${FUNDING_KIND}' != '${None}' Set to dictionary ${tender_parameters} fundingKind=${FUNDING_KIND} | 166 | Run keyword if '${FUNDING_KIND}' != '${None}' Set to dictionary ${tender_parameters} fundingKind=${FUNDING_KIND} |
151 | - ${tender_data}= Підготувати дані для створення тендера ${tender_parameters} | 167 | + ${plan_data}= Run as ${tender_owner} Пошук плану по ідентифікатору ${ARTIFACT.tender_uaid} |
168 | + Log ${plan_data} | ||
169 | + ${tender_data}= Підготувати дані для створення тендера ${tender_parameters} ${plan_data} | ||
152 | ${adapted_data}= Адаптувати дані для оголошення тендера ${tender_data} | 170 | ${adapted_data}= Адаптувати дані для оголошення тендера ${tender_data} |
153 | ${adapted_data_gmdn}= edit_tender_data_for_gmdn ${adapted_data} ${MODE} ${data_version} | 171 | ${adapted_data_gmdn}= edit_tender_data_for_gmdn ${adapted_data} ${MODE} ${data_version} |
154 | Log ${adapted_data_gmdn} | 172 | Log ${adapted_data_gmdn} |
@@ -198,7 +198,6 @@ Library openprocurement_client.utils | @@ -198,7 +198,6 @@ Library openprocurement_client.utils | ||
198 | ... ${ARTIFACT.tender_id} | 198 | ... ${ARTIFACT.tender_id} |
199 | ... ${tender_data} | 199 | ... ${tender_data} |
200 | ... access_token=${ARTIFACT.tender_owner_access_token} | 200 | ... access_token=${ARTIFACT.tender_owner_access_token} |
201 | - #${tender}= Call Method ${USERS.users['${username}'].client} create_tender ${tender_data} | ||
202 | Log ${tender} | 201 | Log ${tender} |
203 | ${access_token}= Get Variable Value ${tender.access.token} | 202 | ${access_token}= Get Variable Value ${tender.access.token} |
204 | ${status}= Set Variable If 'open' in '${MODE}' active.tendering ${EMPTY} | 203 | ${status}= Set Variable If 'open' in '${MODE}' active.tendering ${EMPTY} |
@@ -323,9 +323,9 @@ def test_tender_data_planning(params): | @@ -323,9 +323,9 @@ def test_tender_data_planning(params): | ||
323 | if params.get('moz_integration'): | 323 | if params.get('moz_integration'): |
324 | id_cpv = 336 | 324 | id_cpv = 336 |
325 | elif params.get('road_index'): | 325 | elif params.get('road_index'): |
326 | - id_cpv = 'road' | 326 | + id_cpv = fake.road_cpv()[:4] |
327 | elif params.get('gmdn_index'): | 327 | elif params.get('gmdn_index'): |
328 | - id_cpv = 'gmdn' | 328 | + id_cpv = fake.gmdn_cpv()[:4] |
329 | else: | 329 | else: |
330 | id_cpv = fake.cpv()[:4] | 330 | id_cpv = fake.cpv()[:4] |
331 | cpv_data = test_item_data(id_cpv) | 331 | cpv_data = test_item_data(id_cpv) |
@@ -339,7 +339,7 @@ def test_tender_data_planning(params): | @@ -339,7 +339,7 @@ def test_tender_data_planning(params): | ||
339 | del data['quantity'] | 339 | del data['quantity'] |
340 | del data['unit'] | 340 | del data['unit'] |
341 | for i in range(params['number_of_items']): | 341 | for i in range(params['number_of_items']): |
342 | - item_data=test_item_data(id_cpv) | 342 | + item_data = test_item_data(id_cpv) |
343 | del item_data['deliveryAddress'] | 343 | del item_data['deliveryAddress'] |
344 | del item_data['deliveryLocation'] | 344 | del item_data['deliveryLocation'] |
345 | item_data['deliveryDate']['endDate'] = (get_now() + timedelta(days=10)).replace(hour=0, minute=0, second=0, microsecond=0).isoformat() | 345 | item_data['deliveryDate']['endDate'] = (get_now() + timedelta(days=10)).replace(hour=0, minute=0, second=0, microsecond=0).isoformat() |
@@ -862,7 +862,7 @@ def test_elimination_report(corruption, relatedParty_id): | @@ -862,7 +862,7 @@ def test_elimination_report(corruption, relatedParty_id): | ||
862 | 862 | ||
863 | 863 | ||
864 | def test_tender_data_esco(params, submissionMethodDetails, plan_data): | 864 | def test_tender_data_esco(params, submissionMethodDetails, plan_data): |
865 | - data = test_tender_data(params, ('tender',), submissionMethodDetails, plan_data) | 865 | + data = test_tender_data(params, plan_data, ('tender',), submissionMethodDetails) |
866 | data['procurementMethodType'] = 'esco' | 866 | data['procurementMethodType'] = 'esco' |
867 | data['title_en'] = "[TESTING]" | 867 | data['title_en'] = "[TESTING]" |
868 | for item_number, item in enumerate(data['items']): | 868 | for item_number, item in enumerate(data['items']): |
@@ -19,6 +19,7 @@ ${MOZ_INTEGRATION} ${False} | @@ -19,6 +19,7 @@ ${MOZ_INTEGRATION} ${False} | ||
19 | ${VAT_INCLUDED} ${True} | 19 | ${VAT_INCLUDED} ${True} |
20 | ${ROAD_INDEX} ${False} | 20 | ${ROAD_INDEX} ${False} |
21 | ${GMDN_INDEX} ${False} | 21 | ${GMDN_INDEX} ${False} |
22 | +${PLAN_TENDER} ${True} | ||
22 | 23 | ||
23 | *** Test Cases *** | 24 | *** Test Cases *** |
24 | Можливість оголосити тендер | 25 | Можливість оголосити тендер |
Please
register
or
login
to post a comment