Commit 205caf2665a8e88326205eb1d3f3aaf2d650812f

Authored by OrysiaDrabych
1 parent 8a345fda

Add get_number_of_minutes function

... ... @@ -15,7 +15,9 @@ Resource base_keywords.robot
15 15
16 16
17 17 Можливість продовжити період подання пропозиції на ${number_of_days} днів
18   - ${endDate}= add_minutes_to_date ${USERS.users['${tender_owner}'].tender_data.data.tenderPeriod.endDate} ${number_of_days}
  18 + ${period_intervals}= compute_intrs ${BROKERS} ${used_brokers}
  19 + ${number_of_minutes}= get_number_of_minutes ${number_of_days} ${period_intervals.${MODE}.accelerator}
  20 + ${endDate}= add_minutes_to_date ${USERS.users['${tender_owner}'].tender_data.data.tenderPeriod.endDate} ${number_of_minutes}
19 21 Можливість змінити поле tenderPeriod.endDate тендера на ${endDate}
20 22 Remove From Dictionary ${USERS.users['${tender_owner}'].tender_data.data.tenderPeriod} endDate
21 23
... ...
... ... @@ -50,6 +50,8 @@ def subtraction(value1, value2):
50 50 def create_fake_value_amount():
51 51 return fake.random_int(min=1)
52 52
  53 +def get_number_of_minutes(days, accelerator):
  54 + return 1440 * int(days) / accelerator
53 55
54 56 def field_with_id(prefix, sentence):
55 57 return u"{}-{}: {}".format(prefix, fake.uuid4()[:8], sentence)
... ...
... ... @@ -52,10 +52,11 @@ from .initial_data import (
52 52 create_fake_value_amount,
53 53 test_change_document_data,
54 54 convert_amount,
  55 + get_number_of_minutes,
55 56 )
56 57 from barbecue import chef
57 58 from restkit import request
58   -# End of non-pointless imports
  59 +# End of non-pointless import
59 60 import os
60 61 import re
61 62
... ...
Please register or login to post a comment