Added sleep to help prevent timing issues

This commit is contained in:
Logan Lipke
2020-07-16 12:23:39 -07:00
parent 933aac9b43
commit 2ec5e0502c

View File

@@ -60,7 +60,7 @@ class IPV4L4(LFCliBase):
expected_passes += 1 expected_passes += 1
if new_list[item] > old_list[item]: if new_list[item] > old_list[item]:
passes += 1 passes += 1
#print(item, new_list[item], old_list[item], passes, expected_passes) # print(item, old_list[item], new_list[item], passes, expected_passes)
if passes == expected_passes: if passes == expected_passes:
return True return True
@@ -70,6 +70,7 @@ class IPV4L4(LFCliBase):
return False return False
def __get_values(self): def __get_values(self):
time.sleep(1)
cx_list = self.json_get("layer4/list?fields=name,bytes-rd", debug_=self.debug) cx_list = self.json_get("layer4/list?fields=name,bytes-rd", debug_=self.debug)
# print("==============\n", cx_list, "\n==============") # print("==============\n", cx_list, "\n==============")
cx_map = {} cx_map = {}
@@ -151,7 +152,7 @@ def main():
station_list = LFUtils.portNameSeries(prefix_="sta", start_id_=0, end_id_=1, padding_number_=10000) station_list = LFUtils.portNameSeries(prefix_="sta", start_id_=0, end_id_=1, padding_number_=10000)
ip_test = IPV4L4(lfjson_host, lfjson_port, ssid="jedway-wpa2-x2048-4-4", password="jedway-wpa2-x2048-4-4", ip_test = IPV4L4(lfjson_host, lfjson_port, ssid="jedway-wpa2-x2048-4-4", password="jedway-wpa2-x2048-4-4",
security="wpa2", station_list=station_list, url="dl http://10.40.0.1 /dev/null", test_duration="5m", security="wpa2", station_list=station_list, url="dl http://10.40.0.1 /dev/null", test_duration="5m",
requests_per_ten=600) requests_per_ten=600, _debug_on=False)
ip_test.cleanup(station_list) ip_test.cleanup(station_list)
ip_test.build() ip_test.build()
if not ip_test.passes(): if not ip_test.passes():