test_ipv4_ttls: Clean up unused parameters and move all self methods to init

Signed-off-by: Matthew Stidham <stidmatt@gmail.com>
This commit is contained in:
Matthew Stidham
2021-11-24 10:39:52 -08:00
parent b5a89c9569
commit 0749253c4c

View File

@@ -64,6 +64,7 @@ class TTLSTest(Realm):
_exit_on_error=False, _exit_on_error=False,
_exit_on_fail=False): _exit_on_fail=False):
super().__init__(lfclient_host=host, lfclient_port=port, debug_=_debug_on, _exit_on_fail=_exit_on_fail) super().__init__(lfclient_host=host, lfclient_port=port, debug_=_debug_on, _exit_on_fail=_exit_on_fail)
self.resulting_endpoints = {}
self.host = host self.host = host
self.port = port self.port = port
self.ssid = ssid self.ssid = ssid
@@ -154,7 +155,6 @@ class TTLSTest(Realm):
def build(self, def build(self,
extra_securities=None): extra_securities=None):
# Build stations # Build stations
keyphrase = "[BLANK]"
self.station_profile.use_security(self.security, self.ssid, passwd=self.password) self.station_profile.use_security(self.security, self.ssid, passwd=self.password)
if extra_securities is not None: if extra_securities is not None:
@@ -277,7 +277,6 @@ class TTLSTest(Realm):
debug=self.debug) debug=self.debug)
def collect_endp_stats(self, endp_map, traffic_type="TCP"): def collect_endp_stats(self, endp_map, traffic_type="TCP"):
self.resulting_endpoints = {}
print("Collecting Data") print("Collecting Data")
fields = "?fields=name,tx+bytes,rx+bytes" fields = "?fields=name,tx+bytes,rx+bytes"
for (cx_name, endps) in endp_map.items(): for (cx_name, endps) in endp_map.items():
@@ -302,7 +301,6 @@ class TTLSTest(Realm):
self.compare_vals("test" + traffic_type + "-B TX", ptest_b_tx) self.compare_vals("test" + traffic_type + "-B TX", ptest_b_tx)
self.compare_vals("test" + traffic_type + "-B RX", ptest_b_rx) self.compare_vals("test" + traffic_type + "-B RX", ptest_b_rx)
except Exception as e: except Exception as e:
print("Is this the function having the error?") print("Is this the function having the error?")
self.error(e) self.error(e)