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.orgsrs_andre has submitted this change. ( https://gerrit.osmocom.org/c/osmo-gsm-tester/+/18789 )
Change subject: epc: refactor run_wait() method and rename to prepare_proc()
......................................................................
epc: refactor run_wait() method and rename to prepare_proc()
this refactor no longer enforces blocking operation of the process.
Instead it returns the process object to the caller who
can now run either proc.launch() for non-blocking operation
or proc.launch_sync() for blocking mode.
The non-block mode allos doing other stuff in the background,
for example controlling the rfemu while running a ping.
Change-Id: Ia6372e55a8829f722e40db537d9dfd63a94d1be9
---
M src/osmo_gsm_tester/obj/epc.py
M sysmocom/suites/4g/rrc_idle_mt_ping.py
2 files changed, 6 insertions(+), 4 deletions(-)
Approvals:
pespin: Looks good to me, approved
Jenkins Builder: Verified
diff --git a/src/osmo_gsm_tester/obj/epc.py b/src/osmo_gsm_tester/obj/epc.py
index dfeba74..6f056fc 100644
--- a/src/osmo_gsm_tester/obj/epc.py
+++ b/src/osmo_gsm_tester/obj/epc.py
@@ -76,13 +76,14 @@
return epc_class(testenv, run_node)
- def run_wait(self, name, popen_args):
- ''' Execute process on EPC node, useful for MT traffic '''
+ def prepare_process(self, name, popen_args):
+ ''' Prepare and return a process to run on EPC node.
+ Caller calls either launch() or launch_sync()
+ for non-blocking or blocking operation respectively '''
if self._run_node.is_local():
proc = process.Process(name, self.run_dir, popen_args)
else:
proc = self.rem_host.RemoteProcess(name, popen_args)
- proc.launch_sync()
return proc
###################
diff --git a/sysmocom/suites/4g/rrc_idle_mt_ping.py b/sysmocom/suites/4g/rrc_idle_mt_ping.py
index fb3c32c..dcabe21 100755
--- a/sysmocom/suites/4g/rrc_idle_mt_ping.py
+++ b/sysmocom/suites/4g/rrc_idle_mt_ping.py
@@ -27,7 +27,8 @@
sleep(5)
# Generate MO traffic, send single ping
-proc = epc.run_wait('ping', ('ping', '-c', '1', ue.get_assigned_addr()))
+proc = epc.prepare_process('ping', ('ping', '-c', '1', ue.get_assigned_addr()))
+proc.launch_sync()
output = proc.get_stdout()
# Check paging received
--
To view, visit https://gerrit.osmocom.org/c/osmo-gsm-tester/+/18789
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: Ia6372e55a8829f722e40db537d9dfd63a94d1be9
Gerrit-Change-Number: 18789
Gerrit-PatchSet: 5
Gerrit-Owner: srs_andre <andre at softwareradiosystems.com>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: pespin <pespin at sysmocom.de>
Gerrit-Reviewer: srs_andre <andre at softwareradiosystems.com>
Gerrit-MessageType: merged
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20200615/c845cc0d/attachment.htm>