Attempt to make s2n_dynamic_record_size_test fail less
increase sleep wait time for tcpdump
print tcpdump output if it fails
@@ -161,7 +161,7 @@ def run_test(host, port, ssl_version, cipher, threshold):
ret = try_dynamic_record(host, port, cipher_name, ssl_version, threshold)
# wait for pipe ready
- sleep(1)
+ sleep(2)
subprocess.call(["sudo", "killall", "-9", "tcpdump"])
out = tcpdump.communicate()[0].decode("utf-8")
if out == '':
@@ -228,8 +228,13 @@ def analyze_latency_dump(array):
def analyze_throughput_dump(array):
failed = 1
+ array_len = len(array)
for i in range(18, 36):
+ if i >= array_len:
+ print("Array len is ", array_len, ", expecting >= ", i)
+ print(array)
+ return failed
output = array[i]
# print(output)
pos = output.find("length")
