Change in osmo-ttcn3-hacks[master]: remsim: Reset the bankd-side state at start of test

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/.

laforge gerrit-no-reply at lists.osmocom.org
Wed Dec 4 21:26:42 UTC 2019


laforge has submitted this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/16494 )

Change subject: remsim: Reset the bankd-side state at start of test
......................................................................

remsim: Reset the bankd-side state at start of test

In general we don't want that bankd retains state from one test
case to another.  Let's issue the new RSPRO ResetStateReq at the
start of each relevant test

Change-Id: If810ccbbc848dd2448a4eaea20c80f60f15a2e84
---
M remsim/RemsimBankd_Tests.ttcn
1 file changed, 9 insertions(+), 0 deletions(-)

Approvals:
  Jenkins Builder: Verified
  laforge: Looks good to me, approved



diff --git a/remsim/RemsimBankd_Tests.ttcn b/remsim/RemsimBankd_Tests.ttcn
index bbdea6d..4e87024 100644
--- a/remsim/RemsimBankd_Tests.ttcn
+++ b/remsim/RemsimBankd_Tests.ttcn
@@ -81,6 +81,7 @@
 testcase TC_createMapping() runs on bankd_test_CT {
 	f_init();
 	as_connectBankReq(bid := mp_bank_id, nslots := mp_num_slots);
+	f_rspro_srv_reset_state(ok);
 	var BankSlot bs := { bankId := mp_bank_id, slotNr := 0 };
 	var ClientSlot cs := { clientId := 23, slotNr := 42 };
 	f_rspro_srv_create_slotmap(cs, bs);
@@ -91,6 +92,7 @@
 testcase TC_createMapping_busySlot() runs on bankd_test_CT {
 	f_init();
 	as_connectBankReq(bid := mp_bank_id, nslots := mp_num_slots);
+	f_rspro_srv_reset_state(ok);
 	var BankSlot bs := { bankId := mp_bank_id, slotNr := 0 };
 	var ClientSlot cs := { clientId := 23, slotNr := 42 };
 	f_rspro_srv_create_slotmap(cs, bs);
@@ -102,6 +104,7 @@
 testcase TC_createMapping_invalidSlot() runs on bankd_test_CT {
 	f_init();
 	as_connectBankReq(bid := mp_bank_id, nslots := mp_num_slots);
+	f_rspro_srv_reset_state(ok);
 	var BankSlot bs := { bankId := mp_bank_id, slotNr := 200 };
 	var ClientSlot cs := { clientId := 23, slotNr := 42 };
 	f_rspro_srv_create_slotmap(cs, bs, exp_res := illegalSlotId);
@@ -112,6 +115,7 @@
 testcase TC_createMapping_invalidBank() runs on bankd_test_CT {
 	f_init();
 	as_connectBankReq(bid := mp_bank_id, nslots := mp_num_slots);
+	f_rspro_srv_reset_state(ok);
 	var BankSlot bs := { bankId := 200, slotNr := 0 };
 	var ClientSlot cs := { clientId := 23, slotNr := 42 };
 	f_rspro_srv_create_slotmap(cs, bs, exp_res := illegalBankId);
@@ -122,6 +126,7 @@
 testcase TC_removeMapping_unknownMap() runs on bankd_test_CT {
 	f_init();
 	as_connectBankReq(bid := mp_bank_id, nslots := mp_num_slots);
+	f_rspro_srv_reset_state(ok);
 	var BankSlot bs := { bankId := mp_bank_id, slotNr := 0 };
 	var ClientSlot cs := { clientId := 23, slotNr := 42 };
 	f_rspro_srv_remove_slotmap(cs, bs, exp_res := unknownSlotmap);
@@ -132,6 +137,7 @@
 testcase TC_removeMapping() runs on bankd_test_CT {
 	f_init();
 	as_connectBankReq(bid := mp_bank_id, nslots := mp_num_slots);
+	f_rspro_srv_reset_state(ok);
 	var BankSlot bs := { bankId := mp_bank_id, slotNr := 0 };
 	var ClientSlot cs := { clientId := 23, slotNr := 42 };
 	f_rspro_srv_create_slotmap(cs, bs);
@@ -180,6 +186,7 @@
 
 	f_init();
 	as_connectBankReq(bid := mp_bank_id, nslots := mp_num_slots);
+	f_rspro_srv_reset_state(ok);
 
 	var BankSlot bs := { bankId := mp_bank_id, slotNr := 0 };
 	f_rspro_srv_create_slotmap(rspro[0].rspro_client_slot, bs);
@@ -201,6 +208,7 @@
 
 	f_init();
 	as_connectBankReq(bid := mp_bank_id, nslots := mp_num_slots);
+	f_rspro_srv_reset_state(ok);
 
 	var BankSlot bs := { bankId := mp_bank_id, slotNr := 0 };
 	f_rspro_srv_create_slotmap(rspro[0].rspro_client_slot, bs);
@@ -248,6 +256,7 @@
 
 	f_init();
 	as_connectBankReq(bid := mp_bank_id, nslots := mp_num_slots);
+	f_rspro_srv_reset_state(ok);
 
 	var BankSlot bs := { bankId := mp_bank_id, slotNr := 0 };
 	f_rspro_srv_create_slotmap(rspro[0].rspro_client_slot, bs);

-- 
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/16494
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: If810ccbbc848dd2448a4eaea20c80f60f15a2e84
Gerrit-Change-Number: 16494
Gerrit-PatchSet: 1
Gerrit-Owner: laforge <laforge at osmocom.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge at osmocom.org>
Gerrit-MessageType: merged
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20191204/713449a0/attachment.htm>


More information about the gerrit-log mailing list