diff options
author | Hansen, Tony (th1395) <th1395@att.com> | 2020-01-27 22:28:34 +0000 |
---|---|---|
committer | Hansen, Tony (th1395) <th1395@att.com> | 2020-01-31 19:10:12 +0000 |
commit | db08ae5dac684a1155dedfd199ae4e372c82e9df (patch) | |
tree | ad8af5f477614099f32f7d430bbc01a1101d76ce /miss_htbt_service/misshtbtd.py | |
parent | c23a966aaa7e9172c42d8439a3a208000d1762dc (diff) |
increase code coverage
Change-Id: I30632d2e34401f8eff6e67b9b3d8abba32e80050
Signed-off-by: Hansen, Tony (th1395) <th1395@att.com>
Issue-ID: DCAEGEN2-1902
Signed-off-by: Hansen, Tony (th1395) <th1395@att.com>
Diffstat (limited to 'miss_htbt_service/misshtbtd.py')
-rw-r--r-- | miss_htbt_service/misshtbtd.py | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/miss_htbt_service/misshtbtd.py b/miss_htbt_service/misshtbtd.py index 790ab6a..c56ad99 100644 --- a/miss_htbt_service/misshtbtd.py +++ b/miss_htbt_service/misshtbtd.py @@ -1,6 +1,6 @@ #!/usr/bin/env python3 # ============LICENSE_START======================================================= -# Copyright (c) 2017-2018 AT&T Intellectual Property. All rights reserved. +# Copyright (c) 2017-2020 AT&T Intellectual Property. All rights reserved. # Copyright (c) 2019 Pantheon.tech. All rights reserved. # ================================================================================ # Licensed under the Apache License, Version 2.0 (the "License"); @@ -16,7 +16,6 @@ # limitations under the License. # ============LICENSE_END========================================================= # -# ECOMP is a trademark and service mark of AT&T Intellectual Property. # This is a main process that does the following # - Creates the CBS polling process that indicates the periodic download of # configuration file from CBS @@ -109,11 +108,11 @@ def create_database(update_db, jsfile, ip_address, port_num, user_name, password def read_hb_common(user_name,password,ip_address,port_num,db_name): envPytest = os.getenv('pytest', "") if (envPytest == 'test'): - hbc_pid = 10 - hbc_srcName = "srvc_name" - hbc_time = 1584595881 - hbc_state = "RUNNING" - return hbc_pid, hbc_state, hbc_srcName, hbc_time + hbc_pid = 10 + hbc_srcName = "srvc_name" + hbc_time = 1584595881 + hbc_state = "RUNNING" + return hbc_pid, hbc_state, hbc_srcName, hbc_time connection_db = heartbeat.postgres_db_open(user_name,password,ip_address,port_num,db_name) cur = connection_db.cursor() query_value = "SELECT process_id,source_name,last_accessed_time,current_state FROM hb_common;" |