Commit 4a3600fabae8b19a02b0a9180c780f8c72cbbe31

Authored by ivanka12
1 parent 0da9856d

add create_fake_period method

... ... @@ -60,6 +60,14 @@ def create_fake_date():
60 60 return get_now().isoformat()
61 61
62 62
  63 +def create_fake_period(days=0, hours=0, minutes=0):
  64 + data = {
  65 + "startDate": get_now().isoformat(),
  66 + "endDate": (get_now() + timedelta(days=days, hours=hours, minutes=minutes)).isoformat()
  67 + }
  68 + return data
  69 +
  70 +
63 71 def subtraction(value1, value2):
64 72 if "." in str (value1) or "." in str (value2):
65 73 return (float (value1) - float (value2))
... ...
... ... @@ -23,6 +23,7 @@ from .initial_data import (
23 23 create_fake_number,
24 24 create_fake_date,
25 25 create_fake_funder,
  26 + create_fake_period,
26 27 get_fake_funder_scheme,
27 28 fake,
28 29 subtraction,
... ...
Please register or login to post a comment