aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--pgw/PGW_Tests.ttcn25
1 files changed, 25 insertions, 0 deletions
diff --git a/pgw/PGW_Tests.ttcn b/pgw/PGW_Tests.ttcn
index 02c28ccf..1a02c4dc 100644
--- a/pgw/PGW_Tests.ttcn
+++ b/pgw/PGW_Tests.ttcn
@@ -685,8 +685,32 @@ testcase TC_deleteSession_unknown() runs on PGW_Test_CT {
vc_conn.done;
}
+/* Test charging over Gy interface. */
+private function f_TC_gy_charging_cc_time() runs on PGW_Session_CT {
+ var default d;
+ f_create_session();
+
+ /* We should receive an update even if no traffic is sent: */
+ as_DIA_Gy_CCR(UPDATE_REQUEST);
+
+ d := activate(as_DIA_Gy_CCR(UPDATE_REQUEST));
+ f_ping4(mp_ping_hostname);
+ /* Let the CCA reach the GGSN */
+ f_sleep(0.5);
+ deactivate(d);
+ f_delete_session(omit, g_teic, '10'O);
+ setverdict(pass);
+}
+testcase TC_gy_charging_cc_time() runs on PGW_Test_CT {
+ var PGW_Session_CT vc_conn;
+ var SessionPars pars := valueof(t_SessionPars('001010123456789'H, "tun23"));
+ pars.gy_validity_time := 3; /* Grant access for 3 seconds, needs to be re-validated afterwards */
+ f_init();
+ vc_conn := f_start_handler(refers(f_TC_gy_charging_cc_time), pars);
+ vc_conn.done;
+}
control {
execute( TC_tx_echo() );
@@ -695,6 +719,7 @@ control {
execute( TC_createSession_ping4_256() );
execute( TC_createSession_deleteSession() );
execute( TC_deleteSession_unknown() );
+ execute( TC_gy_charging_cc_time() );
}