From b4176e52009f33193418ce05438b768d50091e5d Mon Sep 17 00:00:00 2001 From: Neels Hofmeyr Date: Tue, 13 Jul 2021 23:03:07 +0200 Subject: handover tests: test passing of penalty timeout With recent addition of fake time in handover_test ('wait cmd'), show how a penalty timeout in handover decision 2 passes and allows a handover again after due time. Related: SYS#5198 Change-Id: I65e59cc7309778cf9d71612669ce84d101c8135e --- tests/handover/test_max_ta.ho_vty | 16 ++++++++++++++++ tests/handover/test_penalty_timer.ho_vty | 14 ++++++++++++++ 2 files changed, 30 insertions(+) (limited to 'tests') diff --git a/tests/handover/test_max_ta.ho_vty b/tests/handover/test_max_ta.ho_vty index 05c4a76d5..56dbb19d1 100644 --- a/tests/handover/test_max_ta.ho_vty +++ b/tests/handover/test_max_ta.ho_vty @@ -7,15 +7,31 @@ create-n-bts 2 set-ts-use trx 0 0 states * TCH/F - - - - - - + network bts 0 handover2 maximum distance 5 + handover2 penalty-time max-distance 17 + meas-rep lchan 0 0 1 0 rxlev 30 rxqual 0 ta 5 neighbors 20 expect-no-chan meas-rep lchan 0 0 1 0 rxlev 30 rxqual 0 ta 6 neighbors 20 expect-ho from lchan 0 0 1 0 to lchan 1 0 1 0 expect-ts-use trx 0 0 states * - - - - - - - expect-ts-use trx 1 0 states * TCH/F - - - - - - + +# Penalty timer after TA was exceeded is running, so no handover back to the better cell: meas-rep lchan 1 0 1 0 rxlev 20 rxqual 0 ta 6 neighbors 30 expect-no-chan +wait 16 +# Penalty timer still running +meas-rep lchan 1 0 1 0 rxlev 20 rxqual 0 ta 6 neighbors 30 +expect-no-chan + +wait 1 +# Now 17 seconds have passed, timeout is done, and a handover is performed again. +meas-rep lchan 1 0 1 0 rxlev 20 rxqual 0 ta 6 neighbors 30 +expect-ho from lchan 1 0 1 0 to lchan 0 0 1 0 +expect-ts-use trx 0 0 states * TCH/F - - - - - - +expect-ts-use trx 1 0 states * - - - - - - - diff --git a/tests/handover/test_penalty_timer.ho_vty b/tests/handover/test_penalty_timer.ho_vty index 9511b5e32..8d864a2d4 100644 --- a/tests/handover/test_penalty_timer.ho_vty +++ b/tests/handover/test_penalty_timer.ho_vty @@ -29,3 +29,17 @@ expect-ts-use trx 1 0 states * - - - - - - - # No handover because the penalty timer is still running meas-rep lchan 0 0 1 0 rxlev 20 rxqual 0 ta 0 neighbors 30 expect-no-chan + +wait 17 +# at this point, the penalty timer has not yet expired. (4+1+17 = 22 < 23) +meas-rep lchan 0 0 1 0 rxlev 20 rxqual 0 ta 0 neighbors 30 +expect-no-chan +expect-ts-use trx 0 0 states * TCH/F - - - - - - +expect-ts-use trx 1 0 states * - - - - - - - + +wait 1 +# now the penalty timer of 23 seconds has passed and the handover is attempted again. +meas-rep lchan 0 0 1 0 rxlev 20 rxqual 0 ta 0 neighbors 30 +expect-ho from lchan 0 0 1 0 to lchan 1 0 1 0 +expect-ts-use trx 0 0 states * - - - - - - - +expect-ts-use trx 1 0 states * TCH/F - - - - - - -- cgit v1.2.3