Change in osmo-gsm-tester[master]: 4g: add checks for received PRACHs for ping tests

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

srs_andre gerrit-no-reply at lists.osmocom.org
Thu Jan 7 16:38:14 UTC 2021


srs_andre has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-gsm-tester/+/22043 )


Change subject: 4g: add checks for received PRACHs for ping tests
......................................................................

4g: add checks for received PRACHs for ping tests

the tests already check for sent PRACHs, this will
also check for received PRACHs on the eNB to make
sure we don't detect any fake PRACHs during the tests.

Change-Id: Ib23056b1ad4b18a7dde6cd0c997f5114ac2acb61
---
M sysmocom/suites/4g/rrc_idle_mo_ping.py
M sysmocom/suites/4g/rrc_idle_mt_ping.py
2 files changed, 19 insertions(+), 5 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-gsm-tester refs/changes/43/22043/1

diff --git a/sysmocom/suites/4g/rrc_idle_mo_ping.py b/sysmocom/suites/4g/rrc_idle_mo_ping.py
index ced798d..389e5a2 100755
--- a/sysmocom/suites/4g/rrc_idle_mo_ping.py
+++ b/sysmocom/suites/4g/rrc_idle_mo_ping.py
@@ -31,9 +31,16 @@
 output = proc.get_stdout()
 
 # Check PRACH transmissions
+num_prachs = 2
 num_prach_sent = ue.get_counter('prach_sent')
-if num_prach_sent != 2:
-    raise Exception("Expected to have sent exactly 2 PRACHs, but in fact sent {}".format(num_prach_sent))
+if num_prach_sent != num_prachs:
+    raise Exception("Expected to have sent exactly {} PRACHs, but in fact sent {}".format(num_prachs, num_prach_sent))
 
+# Check PRACH receptions
+num_prach_received = enb.get_counter('prach_received')
+if num_prach_sent != num_prachs:
+    raise Exception("Expected to have received exactly {} PRACHs, but in fact received {}".format(num_prachs, num_prach_received))
+
+output += "\nnum_prach_sent={}\nnum_prach_received={}\n".format(num_prach_sent, num_prach_received)
 print(output)
 test.set_report_stdout(output)
diff --git a/sysmocom/suites/4g/rrc_idle_mt_ping.py b/sysmocom/suites/4g/rrc_idle_mt_ping.py
index dcabe21..bdebb26 100755
--- a/sysmocom/suites/4g/rrc_idle_mt_ping.py
+++ b/sysmocom/suites/4g/rrc_idle_mt_ping.py
@@ -26,7 +26,7 @@
 # Wait a bit
 sleep(5)
 
-# Generate MO traffic, send single ping
+# Generate MT traffic, send single ping
 proc = epc.prepare_process('ping', ('ping', '-c', '1', ue.get_assigned_addr()))
 proc.launch_sync()
 output = proc.get_stdout()
@@ -37,9 +37,16 @@
     raise Exception("Expected to receive exactly 1 paging message, but in fact received {}".format(num_paging_received))
 
 # Check PRACH transmissions
+num_prachs = 2
 num_prach_sent = ue.get_counter('prach_sent')
-if num_prach_sent != 2:
-    raise Exception("Expected to have sent exactly 2 PRACHs, but in fact sent {}".format(num_prach_sent))
+if num_prach_sent != num_prachs:
+    raise Exception("Expected to have sent exactly {} PRACHs, but in fact sent {}".format(num_prachs, num_prach_sent))
 
+# Check PRACH receptions
+num_prach_received = enb.get_counter('prach_received')
+if num_prach_sent != num_prachs:
+    raise Exception("Expected to have received exactly {} PRACHs, but in fact received {}".format(num_prachs, num_prach_received))
+
+output += "\nnum_prach_sent={}\nnum_prach_received={}\n".format(num_prach_sent, num_prach_received)
 print(output)
 test.set_report_stdout(output)

-- 
To view, visit https://gerrit.osmocom.org/c/osmo-gsm-tester/+/22043
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-gsm-tester
Gerrit-Branch: master
Gerrit-Change-Id: Ib23056b1ad4b18a7dde6cd0c997f5114ac2acb61
Gerrit-Change-Number: 22043
Gerrit-PatchSet: 1
Gerrit-Owner: srs_andre <andre at softwareradiosystems.com>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210107/f66af274/attachment.htm>


More information about the gerrit-log mailing list