more tests

This commit is contained in:
Kenneth Kehl
2023-08-14 15:32:22 -07:00
parent b4a2f37ca9
commit b9ba7d018b
10 changed files with 109 additions and 0 deletions

View File

@@ -147,6 +147,8 @@ def purge_functional_test_data(user_email_prefix):
@click.option('-f', '--file_name', required=True,
help="""Full path of the file to upload, file is a contains inbound numbers, one number per line.""")
def insert_inbound_numbers_from_file(file_name):
# TODO maintainability what is the purpose of this command? Who would use it and why?
print("Inserting inbound numbers from {}".format(file_name))
with open(file_name) as file:
sql = "insert into inbound_numbers values('{}', '{}', 'sns', null, True, now(), null);"
@@ -168,6 +170,9 @@ def setup_commands(application):
@click.option('-d', '--day', help="The date to recalculate, as YYYY-MM-DD", required=True,
type=click_dt(format='%Y-%m-%d'))
def rebuild_ft_billing_for_day(service_id, day):
# TODO maintainability what is the purpose of this command? Who would use it and why?
"""
Rebuild the data in ft_billing for the given service_id and date
"""
@@ -386,6 +391,8 @@ def populate_service_volume_intentions(file_name):
# [1] SMS:: volume intentions for service
# [2] Email:: volume intentions for service
# TODO maintainability what is the purpose of this command? Who would use it and why?
with open(file_name, 'r') as f:
for line in itertools.islice(f, 1, None):
columns = line.split(',')