aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/tests/vty_test_runner.py
diff options
context:
space:
mode:
authorNeels Hofmeyr <nhofmeyr@sysmocom.de>2017-02-03 04:23:46 +0100
committerNeels Hofmeyr <nhofmeyr@sysmocom.de>2017-02-03 04:48:27 +0100
commitba1468e4c66a3f6d5eef2f8ad67188805d07c9b6 (patch)
tree61629d4c9ba240a4bca9c09872d470874e5062d4 /openbsc/tests/vty_test_runner.py
parentb39053ad6de50df5a2efcb4ec0c6551020b513e1 (diff)
vty tests: testBSCreload: ipa_handle_small: ensure rx of 4 bytes
Diffstat (limited to 'openbsc/tests/vty_test_runner.py')
-rw-r--r--openbsc/tests/vty_test_runner.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/openbsc/tests/vty_test_runner.py b/openbsc/tests/vty_test_runner.py
index 3fbe20d09..64fd86dc6 100644
--- a/openbsc/tests/vty_test_runner.py
+++ b/openbsc/tests/vty_test_runner.py
@@ -1239,6 +1239,8 @@ def nat_msc_test(x, ip, port, verbose = False):
def ipa_handle_small(x, verbose = False):
s = data2str(x.recv(4))
+ if len(s) != 4*2:
+ raise Exception("expected to receive 4 bytes, but got %d (%r)" % (len(s)/2, s))
if "0001fe00" == s:
if (verbose):
print "\tBSC <- NAT: PING?"