Change in osmo-ttcn3-hacks[master]: WIP: Introduce NS test cases

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

lynxis lazus gerrit-no-reply at lists.osmocom.org
Mon Jan 11 02:05:27 UTC 2021


lynxis lazus has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/22091 )


Change subject: WIP: Introduce NS test cases
......................................................................

WIP: Introduce NS test cases

Change-Id: Ic619a374b88879d3116f8f28afb14401c3e3192b
---
M library/Osmocom_Gb_Types.ttcn
A ns/NS_Tests.default
A ns/NS_Tests.fr.cfg
A ns/NS_Tests.ttcn
A ns/NS_Tests.udp.cfg
A ns/expected-results.xml
A ns/gen_links.sh
A ns/osmo-ns.fr.cfg
A ns/osmo-ns.udp.cfg
A ns/regen_makefile.sh
10 files changed, 683 insertions(+), 0 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/91/22091/1

diff --git a/library/Osmocom_Gb_Types.ttcn b/library/Osmocom_Gb_Types.ttcn
index c532772..c02e61e 100644
--- a/library/Osmocom_Gb_Types.ttcn
+++ b/library/Osmocom_Gb_Types.ttcn
@@ -14,6 +14,14 @@
 	type uint16_t Nsei;
 	type uint16_t BssgpBvci;
 
+	type enumerated OsmoNsDialect {
+		NS2_DIALECT_UNDEF		('00'H),
+		NS2_DIALECT_STATIC_ALIVE	('01'H),
+		NS2_DIALECT_STATIC_RESETBLOCK	('02'H),
+		NS2_DIALECT_IPACCESS		('03'H),
+		NS2_DIALECT_SNS			('04'H)
+	};
+
 	/* TS 48.016 10.3.7 */
 	type enumerated NsPduType {
 		NS_PDUT_NS_UNITDATA	('00000000'B),
diff --git a/ns/NS_Tests.default b/ns/NS_Tests.default
new file mode 100644
index 0000000..951c1c2
--- /dev/null
+++ b/ns/NS_Tests.default
@@ -0,0 +1,27 @@
+[ORDERED_INCLUDE]
+# Common configuration, shared between test suites
+"../Common.cfg"
+
+[LOGGING]
+#*.FileMask := LOG_ALL
+ConsoleMask := ERROR | WARNING | TESTCASE | TIMEROP_START | USER
+
+[MODULE_PARAMETERS]
+Osmocom_VTY_Functions.mp_prompt_prefix := "OsmoNSdummy";
+StatsD_Checker.mp_enable_stats := true;
+
+[TESTPORT_PARAMETERS]
+*.NSVTY.CTRL_MODE := "client"
+*.NSVTY.CTRL_HOSTNAME := "127.0.0.1"
+*.NSVTY.CTRL_PORTNUM := "4240"
+*.NSVTY.CTRL_LOGIN_SKIPPED := "yes"
+*.NSVTY.CTRL_DETECT_SERVER_DISCONNECTED := "yes"
+*.NSVTY.CTRL_READMODE := "buffered"
+*.NSVTY.CTRL_CLIENT_CLEANUP_LINEFEED := "yes"
+*.NSVTY.CTRL_DETECT_CONNECTION_ESTABLISHMENT_RESULT := "yes"
+*.NSVTY.PROMPT1 := "OsmoNSdummy> "
+*.STATSVTY.PROMPT1 := "OsmoNSdummy> "
+
+[MAIN_CONTROLLER]
+
+[EXECUTE]
diff --git a/ns/NS_Tests.fr.cfg b/ns/NS_Tests.fr.cfg
new file mode 100644
index 0000000..91fb5c5
--- /dev/null
+++ b/ns/NS_Tests.fr.cfg
@@ -0,0 +1,57 @@
+[ORDERED_INCLUDE]
+# Common configuration, shared between test suites
+"../Common.cfg"
+# testsuite specific configuration, not expected to change
+"./NS_Tests.default"
+
+[LOGGING]
+
+[MODULE_PARAMETERS]
+NS_Tests.mp_dialect := NS2_DIALECT_IPACCESS
+NS_Tests.mp_nsconfig := {
+	nsei := 2001,
+	role_sgsn := false,
+	handle_sns := false,
+	nsvc := {
+		{
+			provider := {
+				fr := {
+					netdev := "hdlc1",
+					dlci := 16
+				}
+			},
+			nsvci := 1
+		}, {
+			provider := {
+				fr := {
+					netdev := "hdlc2",
+					dlci := 17
+				}
+			},
+			nsvci := 2
+		}, {
+			provider := {
+				fr := {
+					netdev := "hdlc3",
+					dlci := 18
+				}
+			},
+			nsvci := 3
+		}, {
+			provider := {
+				fr := {
+					netdev := "hdlc4",
+					dlci := 19
+				}
+			},
+			nsvci := 4
+		}
+	}
+}
+
+[TESTPORT_PARAMETERS]
+
+[MAIN_CONTROLLER]
+
+[EXECUTE]
+NS_Tests.control
diff --git a/ns/NS_Tests.ttcn b/ns/NS_Tests.ttcn
new file mode 100644
index 0000000..26bef20
--- /dev/null
+++ b/ns/NS_Tests.ttcn
@@ -0,0 +1,338 @@
+module NS_Tests {
+
+/* Osmocom NS test suite for NS over framerelay or udp ip.access style in TTCN-3
+ * (C) 2021 sysmocom s.f.m.c. GmbH <info at sysmocom.de
+ * Author: Alexander Couzens <lynxis at fe80.eu>
+ * All rights reserved.
+ *
+ * Released under the terms of GNU General Public License, Version 2 or
+ * (at your option) any later version.
+ *
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ */
+
+import from General_Types all;
+import from Osmocom_Types all;
+import from Osmocom_Gb_Types all;
+import from NS_CodecPort all;
+import from NS_Types all;
+import from BSSGP_Types all;
+import from UD_Types all;
+import from NS_CodecPort_CtrlFunct all;
+import from NS_Emulation all;
+import from Native_Functions all;
+import from IPL4asp_Types all;
+import from RAW_NS all;
+import from Osmocom_VTY_Functions all;
+import from TELNETasp_PortType all;
+
+modulepar {
+	OsmoNsDialect mp_dialect := NS2_DIALECT_IPACCESS;
+	NSConfiguration mp_nsconfig := {
+		nsei := 96,
+		role_sgsn := false,
+		handle_sns := false,
+		nsvc := {
+			{
+				provider := {
+					ip := {
+						address_family := AF_INET,
+						local_udp_port := 21000,
+						local_ip := "127.0.0.1",
+						remote_udp_port := 23000,
+						remote_ip := "127.0.0.1"
+					}
+				},
+				nsvci := 97
+			}
+		}
+	};
+}
+
+type component RAW_Test_CT extends RAW_NS_CT {
+	port TELNETasp_PT NSVTY;
+}
+
+private function f_init_vty() runs on RAW_Test_CT {
+	map(self:NSVTY, system:NSVTY);
+	f_vty_set_prompts(NSVTY);
+	f_vty_transceive(NSVTY, "enable");
+	f_vty_transceive(NSVTY, "nsvc nsei " & int2str(mp_nsconfig.nsei) & " force-unconfigured");
+}
+
+/* ensure no matching message is received within 'tout' */
+function f_ensure_no_ns(integer idx := 0, boolean answer_alive := false, float tout := 3.0)
+runs on RAW_Test_CT {
+	var PDU_NS nrf;
+
+	timer T := tout;
+	var default d := activate(ax_rx_fail_on_any_ns(idx));
+	T.start;
+	alt {
+	[answer_alive] as_rx_alive_tx_ack();
+	[] T.timeout {
+		setverdict(pass);
+		}
+	}
+	deactivate(d);
+}
+
+function f_fails_except_reset(integer idx := 0, float tout := 15.0)
+runs on RAW_Test_CT {
+	var PDU_NS nrf;
+	timer T := 15.0;
+	T.start;
+	alt {
+	[] NSCP[idx].receive(tr_NS_RESET(*, *, *)) {
+		repeat;
+	}
+	[] NSCP[idx].receive(PDU_NS: ?) -> value nrf {
+		setverdict(fail, "Received unexpected NS: ", nrf);
+		mtc.stop;
+	}
+	[] T.timeout {
+		setverdict(pass);
+		}
+	}
+}
+
+testcase TC_tx_reset() runs on RAW_Test_CT {
+	f_init_vty();
+	f_init_ns_codec(mp_nsconfig, guard_secs := 10.0);
+
+	/* do a NS Reset procedure */
+	f_outgoing_ns_reset();
+
+	f_sleep(1.0);
+}
+
+testcase TC_tx_reset_tx_alive() runs on RAW_Test_CT {
+	f_init_vty();
+	f_init_ns_codec(mp_nsconfig, guard_secs := 10.0);
+
+	/* do a NS Reset procedure */
+	f_outgoing_ns_reset();
+
+	/* check outgoing NS procedure */
+	f_outgoing_ns_alive();
+
+	f_sleep(1.0);
+}
+
+testcase TC_tx_reset_rx_alive() runs on RAW_Test_CT {
+	f_init_vty();
+	f_init_ns_codec(mp_nsconfig, guard_secs := 10.0);
+
+	/* do a NS Reset procedure */
+	f_outgoing_ns_reset();
+
+	/* check outgoing NS procedure */
+	as_rx_alive_tx_ack(oneshot := true);
+
+	f_sleep(1.0);
+}
+
+/* 48.016 7.2 unblock procedure
+ *
+ * TTCN  -> NS: reset
+ * TTCN <-  NS: reset ack
+ * TTCN  -> NS: unblock
+ * TTCN <-  NS: unblock ack
+ */
+testcase TC_tx_unblock() runs on RAW_Test_CT {
+	f_init_vty();
+	f_init_ns_codec(mp_nsconfig, guard_secs := 30.0);
+
+	/* do a NS Reset procedure */
+	f_outgoing_ns_reset();
+	/* send alive acks */
+	activate(as_rx_alive_tx_ack());
+
+	f_outgoing_ns_unblock();
+	f_sleep(1.0);
+}
+
+/* 48.016 7.2 tx unblock retries
+ *
+ * TTCN  -> NS: reset
+ * TTCN <-  NS: reset ack
+ * TTCN  -> NS: unblock
+ * TTCN <-  NS: unblock ack
+ * TTCN  -> NS: unblock
+ * TTCN <-  NS: unblock ack
+ * TTCN  -> NS: unblock
+ * TTCN <-  NS: unblock ack
+ */
+testcase TC_tx_unblock_retries() runs on RAW_Test_CT {
+	f_init_vty();
+	f_init_ns_codec(mp_nsconfig, guard_secs := 30.0);
+
+	/* do a NS Reset procedure */
+	f_outgoing_ns_reset();
+	/* send alive acks */
+	activate(as_rx_alive_tx_ack());
+
+	f_outgoing_ns_unblock();
+	f_outgoing_ns_unblock();
+	f_outgoing_ns_unblock();
+	f_sleep(1.0);
+}
+
+/* 48.016 7.2 block procedure
+ *
+ * TTCN  -> NS: reset
+ * TTCN <-  NS: reset ack
+ * TTCN  -> NS: unblock
+ * TTCN <-  NS: unblock ack
+ * TTCN  -> NS: block
+ * TTCN <-  NS: block ack
+ */
+testcase TC_tx_block() runs on RAW_Test_CT {
+	f_init_vty();
+	f_init_ns_codec(mp_nsconfig, guard_secs := 30.0);
+
+	/* do a NS Reset procedure */
+	f_outgoing_ns_reset();
+	activate(as_rx_alive_tx_ack());
+
+	f_outgoing_ns_unblock();
+	f_sleep(1.0);
+
+	f_outgoing_ns_block(NS_CAUSE_EQUIPMENT_FAILURE);
+	f_sleep(1.0);
+}
+
+/* 48.016 7.4.1 ignore unexpected NS_ALIVE ACK */
+testcase TC_no_reset_alive_ack() runs on RAW_Test_CT {
+	f_init_vty();
+	f_init_ns_codec(mp_nsconfig, guard_secs := 30.0);
+
+	NSCP[0].send(t_NS_ALIVE_ACK);
+	f_fails_except_reset();
+	f_sleep(1.0);
+}
+
+/* 48.016 7.3.1 NS_RESET ack with wrong nsei */
+testcase TC_reset_ack_wrong_nsei() runs on RAW_Test_CT {
+	f_init_vty();
+	f_init_ns_codec(mp_nsconfig, guard_secs := 30.0);
+
+	NSCP[0].receive(tr_NS_RESET(*, g_nsconfig[0].nsvc[0].nsvci, g_nsconfig[0].nsei));
+	NSCP[0].send(ts_NS_RESET_ACK(g_nsconfig[0].nsvc[0].nsvci, g_nsconfig[0].nsei + 20));
+	f_fails_except_reset();
+	f_sleep(1.0);
+}
+
+/* 48.016 7.3.1 NS_RESET ack with wrong nsvci */
+testcase TC_reset_ack_wrong_nsvci() runs on RAW_Test_CT {
+	f_init_vty();
+	f_init_ns_codec(mp_nsconfig, guard_secs := 30.0);
+
+	NSCP[0].receive(tr_NS_RESET(*, g_nsconfig[0].nsvc[0].nsvci, g_nsconfig[0].nsei));
+	NSCP[0].send(ts_NS_RESET_ACK(g_nsconfig[0].nsvc[0].nsvci + 20, g_nsconfig[0].nsei));
+	f_fails_except_reset();
+	f_sleep(1.0);
+}
+
+/* 48.016 7.3.1 NS_RESET ack with wrong nsvci + nsei */
+testcase TC_reset_ack_wrong_nsei_nsvci() runs on RAW_Test_CT {
+	f_init_vty();
+	f_init_ns_codec(mp_nsconfig, guard_secs := 30.0);
+
+	NSCP[0].receive(tr_NS_RESET(*, g_nsconfig[0].nsvc[0].nsvci, g_nsconfig[0].nsei));
+	NSCP[0].send(ts_NS_RESET_ACK(g_nsconfig[0].nsvc[0].nsvci + 20, g_nsconfig[0].nsei + 20));
+	f_fails_except_reset();
+	f_sleep(1.0);
+}
+
+/* 48.016 7.3.1 ignore unexpected NS_RESET_ACK after NS_RESET+ALIVE */
+testcase TC_ignore_reset_ack() runs on RAW_Test_CT {
+	f_init_vty();
+	f_init_ns_codec(mp_nsconfig, guard_secs := 30.0);
+
+	/* do a NS Reset procedure */
+	f_outgoing_ns_reset();
+
+	/* check outgoing NS procedure */
+	as_rx_alive_tx_ack(oneshot := true);
+	activate(as_rx_alive_tx_ack());
+
+	NSCP[0].send(ts_NS_RESET_ACK(g_nsconfig[0].nsvc[0].nsvci, g_nsconfig[0].nsei));
+	f_ensure_no_ns(answer_alive := true, tout := 15.0);
+	f_sleep(1.0);
+}
+
+
+/* 48.016 7.4 test procedure for frame relay with a single nsvci */
+function f_alive_retries_single(boolean reset := false) runs on RAW_Test_CT {
+	f_init_vty();
+	f_init_ns_codec(mp_nsconfig, guard_secs := 60.0);
+
+	/* do a NS Reset procedure */
+	f_outgoing_ns_reset();
+
+	/* wait for one alive and answer it */
+	as_rx_alive_tx_ack(oneshot := true);
+	NSCP[0].receive(t_NS_ALIVE);
+	NSCP[0].receive(t_NS_ALIVE);
+	NSCP[0].receive(t_NS_ALIVE);
+	NSCP[0].receive(t_NS_ALIVE);
+	if (reset) {
+		NSCP[0].receive(tr_NS_RESET(*, g_nsconfig[0].nsvc[0].nsvci, g_nsconfig[0].nsei));
+	} else {
+		f_ensure_no_ns(tout := 10.0);
+	}
+
+	setverdict(pass);
+	f_sleep(1.0);
+}
+
+testcase TC_alive_retries_single_reset() runs on RAW_Test_CT {
+	f_alive_retries_single(reset := true);
+}
+
+testcase TC_alive_retries_single_no_resp() runs on RAW_Test_CT {
+	f_alive_retries_single(reset := false);
+}
+
+control {
+	execute( TC_tx_reset() );
+
+	/* 48.016 7.2 Block procedure */
+	execute( TC_tx_block() );
+	// execute( TC_block_other_nsvc() ); // reset, unblock, sleep(1), block over another nsvci 
+	/* 48.016 7.2 Unblock procedure */
+	execute( TC_tx_unblock() );
+	execute( TC_tx_unblock_retries() );
+	// execute( TC_rx_unblock_tx_unblock() ); // wait for an rx unblock pdu, send an unblock pdu, expect unblock ack pdu
+	// execute( TC_unblockable() ); // block a NS-VCI via vty, try block procedure
+
+	/* 48.016 7.2.1 Block Abnormal Condition */
+	/* 48.016 7.2.1 Unblock Abnormal Condition */
+
+	/* 48.016 7.3.1 Abnormal Condition */
+	if (mp_dialect == NS2_DIALECT_STATIC_RESETBLOCK) {
+		execute( TC_reset_ack_wrong_nsei() );
+		execute( TC_reset_ack_wrong_nsvci() );
+		execute( TC_reset_ack_wrong_nsei_nsvci() );
+		// execute( TC_reset_retries() );
+		// execute( TC_reset_wrong_nsvci() );
+		// execute( TC_reset_wrong_nsei() );
+	}
+	execute( TC_ignore_reset_ack() );
+
+	/* 48.016 7.4 Test procedure on frame relay */
+	execute( TC_tx_reset_tx_alive() );
+	execute( TC_tx_reset_rx_alive() );
+
+	/* 48.016 7.4.1 Abnormal Condition */
+	if (mp_dialect == NS2_DIALECT_STATIC_RESETBLOCK) {
+		// execute( TC_alive_retries_multi() ); // check if alive retries works and block over an alive nsvc
+		execute( TC_alive_retries_single_reset() );
+	} else if (mp_dialect == NS2_DIALECT_IPACCESS) {
+		execute( TC_alive_retries_single_no_resp() );
+	}
+	execute( TC_no_reset_alive_ack() );
+}
+
+}
diff --git a/ns/NS_Tests.udp.cfg b/ns/NS_Tests.udp.cfg
new file mode 100644
index 0000000..ad87c2e
--- /dev/null
+++ b/ns/NS_Tests.udp.cfg
@@ -0,0 +1,33 @@
+[ORDERED_INCLUDE]
+# Common configuration, shared between test suites
+"../Common.cfg"
+# testsuite specific configuration, not expected to change
+"./NS_Tests.default"
+
+[LOGGING]
+
+[MODULE_PARAMETERS]
+NS_Tests.mp_nsconfig := {
+	nsei := 1234,
+	nsvc := {
+		{
+			provider := {
+				ip := {
+					address_family := AF_INET,
+					local_ip := "127.0.0.1",
+					local_udp_port := 22000,
+					remote_ip := "127.0.0.1",
+					remote_udp_port := 23000
+				}
+			},
+			nsvci := 1234
+		}
+	}
+}
+
+[TESTPORT_PARAMETERS]
+
+[MAIN_CONTROLLER]
+
+[EXECUTE]
+NS_Tests.control
diff --git a/ns/expected-results.xml b/ns/expected-results.xml
new file mode 100644
index 0000000..459744d
--- /dev/null
+++ b/ns/expected-results.xml
@@ -0,0 +1,4 @@
+<?xml version="1.0"?>
+<testsuite name='Titan' tests='1' failures='0' errors='0' skipped='0' inconc='0' time='MASKED'>
+  <testcase classname='NS_Tests' name='TC_NS_connect_reset' time='MASKED'/>
+</testsuite>
diff --git a/ns/gen_links.sh b/ns/gen_links.sh
new file mode 100755
index 0000000..0b38d99
--- /dev/null
+++ b/ns/gen_links.sh
@@ -0,0 +1,61 @@
+#!/bin/bash
+
+BASEDIR=../deps
+
+. ../gen_links.sh.inc
+
+DIR=$BASEDIR/titan.TestPorts.UNIX_DOMAIN_SOCKETasp/src
+FILES="UD_PT.cc  UD_PT.hh  UD_PortType.ttcn  UD_Types.ttcn"
+gen_links $DIR $FILES
+
+DIR=$BASEDIR/titan.Libraries.TCCUsefulFunctions/src
+FILES="TCCInterface_Functions.ttcn TCCConversion_Functions.ttcn TCCConversion.cc TCCInterface.cc TCCInterface_ip.h"
+gen_links $DIR $FILES
+
+DIR=$BASEDIR/titan.TestPorts.Common_Components.Socket-API/src
+FILES="Socket_API_Definitions.ttcn"
+gen_links $DIR $FILES
+
+DIR=$BASEDIR/titan.TestPorts.IPL4asp/src
+FILES="IPL4asp_Functions.ttcn  IPL4asp_PT.cc  IPL4asp_PT.hh IPL4asp_PortType.ttcn  IPL4asp_Types.ttcn  IPL4asp_discovery.cc IPL4asp_protocol_L234.hh"
+gen_links $DIR $FILES
+
+DIR=$BASEDIR/titan.ProtocolModules.NS_v7.3.0/src
+FILES="NS_Types.ttcn"
+gen_links $DIR $FILES
+
+DIR=$BASEDIR/titan.ProtocolModules.BSSGP_v13.0.0/src
+FILES="BSSGP_EncDec.cc  BSSGP_Types.ttcn"
+gen_links $DIR $FILES
+
+DIR=$BASEDIR/titan.ProtocolModules.MobileL3_v13.4.0/src
+FILES="MobileL3_CC_Types.ttcn MobileL3_CommonIE_Types.ttcn MobileL3_GMM_SM_Types.ttcn MobileL3_MM_Types.ttcn MobileL3_RRM_Types.ttcn MobileL3_SMS_Types.ttcn MobileL3_SS_Types.ttcn MobileL3_Types.ttcn"
+gen_links $DIR $FILES
+
+DIR=$BASEDIR/titan.ProtocolModules.LLC_v7.1.0/src
+FILES="LLC_EncDec.cc LLC_Types.ttcn"
+gen_links $DIR $FILES
+
+DIR=$BASEDIR/titan.ProtocolModules.SNDCP_v7.0.0/src
+FILES="SNDCP_Types.ttcn"
+gen_links $DIR $FILES
+
+DIR=$BASEDIR/titan.TestPorts.AF_PACKET/src
+FILES="AF_PACKET_PT.cc AF_PACKET_PT.hh AF_PACKET_PortType.ttcn AF_PACKET_PortTypes.ttcn "
+FILES+="FrameRelay_Types.ttcn FrameRelay_CodecPort.ttcn FrameRelay_Emulation.ttcn Q931_Types.ttcn Q933_Types.ttcn "
+gen_links $DIR $FILES
+
+DIR=$BASEDIR/titan.TestPorts.TELNETasp/src
+FILES="TELNETasp_PT.cc  TELNETasp_PT.hh  TELNETasp_PortType.ttcn"
+gen_links $DIR $FILES
+
+DIR=../library
+FILES="Misc_Helpers.ttcn General_Types.ttcn Osmocom_VTY_Functions.ttcn Native_Functions.ttcn Native_FunctionDefs.cc GSM_Types.ttcn GSM_RR_Types.ttcn Osmocom_Types.ttcn RLCMAC_Templates.ttcn RLCMAC_Types.ttcn RLCMAC_CSN1_Templates.ttcn RLCMAC_CSN1_Types.ttcn RLCMAC_EncDec.cc "
+FILES+="StatsD_Types.ttcn StatsD_CodecPort.ttcn StatsD_CodecPort_CtrlFunct.ttcn StatsD_CodecPort_CtrlFunctdef.cc StatsD_Checker.ttcn "
+FILES+="NS_Provider_IPL4.ttcn NS_Provider_FR.ttcn NS_Emulation.ttcnpp NS_CodecPort.ttcn NS_CodecPort_CtrlFunct.ttcn NS_CodecPort_CtrlFunctDef.cc "
+FILES+="BSSGP_Emulation.ttcnpp Osmocom_Gb_Types.ttcn "
+FILES+="LLC_Templates.ttcn L3_Templates.ttcn L3_Common.ttcn "
+FILES+="PCUIF_Types.ttcn PCUIF_CodecPort.ttcn RAW_NS.ttcnpp "
+gen_links $DIR $FILES
+
+ignore_pp_results
diff --git a/ns/osmo-ns.fr.cfg b/ns/osmo-ns.fr.cfg
new file mode 100644
index 0000000..d1109ab
--- /dev/null
+++ b/ns/osmo-ns.fr.cfg
@@ -0,0 +1,55 @@
+log gsmtap 127.0.0.1
+ logging level set-all debug
+
+log stderr
+ logging filter all 1
+ logging print level 1
+ logging print category 1
+ logging print category-hex 0
+ logging print file basename last
+ logging print extended-timestamp 1
+ logging level set-all debug
+!
+stats interval 0
+stats reporter statsd
+ prefix TTCN3
+ level subscriber
+ remote-ip 127.0.0.1
+ remote-port 8125
+ flush-period 1
+ mtu 1024
+ enable
+
+line vty
+ no login
+ bind 127.0.0.1
+
+ns
+ bind fr hdlcnet1
+  fr hdlcnet1 frnet
+ bind fr hdlcnet2
+  fr hdlcnet2 frnet
+ bind fr hdlcnet3
+  fr hdlcnet3 frnet
+ bind fr hdlcnet4
+  fr hdlcnet4 frnet
+ bind fr hdlcnet5
+  fr hdlcnet5 frnet
+ bind fr hdlcnet6
+  fr hdlcnet6 frnet
+ bind fr hdlcnet7
+  fr hdlcnet7 frnet
+ bind fr hdlcnet8
+  fr hdlcnet8 frnet
+ nse 2001
+  nsvc fr hdlcnet1 dlci 16 nsvci 1
+  nsvc fr hdlcnet2 dlci 17 nsvci 2
+  nsvc fr hdlcnet3 dlci 18 nsvci 3
+  nsvc fr hdlcnet4 dlci 19 nsvci 4
+ nse 2002
+  nsvc fr hdlcnet5 dlci 20 nsvci 5
+  nsvc fr hdlcnet6 dlci 21 nsvci 6
+ nse 2003
+  nsvc fr hdlcnet7 dlci 22 nsvci 7
+  nsvc fr hdlcnet8 dlci 23 nsvci 8
+
diff --git a/ns/osmo-ns.udp.cfg b/ns/osmo-ns.udp.cfg
new file mode 100644
index 0000000..d7c70b4
--- /dev/null
+++ b/ns/osmo-ns.udp.cfg
@@ -0,0 +1,91 @@
+!
+! OsmoNSdummy (1.4.0.326-f57c-dirty) configuration saved from vty
+!!
+!
+log stderr
+ logging filter all 1
+ logging color 0
+ logging print category-hex 0
+ logging print category 1
+ logging print extended-timestamp 1
+ logging print level 1
+ logging print file basename
+ logging level force-all info
+ logging level lglobal debug
+ logging level llapd debug
+ logging level linp debug
+ logging level lmux debug
+ logging level lmi debug
+ logging level lmib debug
+ logging level lsms debug
+ logging level lctrl debug
+ logging level lgtp debug
+ logging level lstats debug
+ logging level lgsup debug
+ logging level loap debug
+ logging level lss7 debug
+ logging level lsccp debug
+ logging level lsua debug
+ logging level lm3ua debug
+ logging level lmgcp debug
+ logging level ljibuf debug
+ logging level lrspro debug
+ logging level lns debug
+ logging level lbssgp debug
+log gsmtap 127.0.0.1
+ logging filter all 0
+ logging color 1
+ logging print category-hex 1
+ logging print category 0
+ logging timestamp 0
+ logging print file 1
+ logging level lglobal debug
+ logging level llapd debug
+ logging level linp debug
+ logging level lmux debug
+ logging level lmi debug
+ logging level lmib debug
+ logging level lsms debug
+ logging level lctrl debug
+ logging level lgtp debug
+ logging level lstats debug
+ logging level lgsup debug
+ logging level loap debug
+ logging level lss7 debug
+ logging level lsccp debug
+ logging level lsua debug
+ logging level lm3ua debug
+ logging level lmgcp debug
+ logging level ljibuf debug
+ logging level lrspro debug
+ logging level lns debug
+ logging level lbssgp debug
+!
+stats reporter statsd
+  disable
+  remote-ip 127.0.0.1
+  remote-port 8125
+  mtu 1024
+  level subscriber
+  prefix TTCN3
+  flush-period 1
+  enable
+stats interval 0
+!
+line vty
+ no login
+!
+ns
+ timer tns-block 3
+ timer tns-block-retries 3
+ timer tns-reset 3
+ timer tns-reset-retries 3
+ timer tns-test 12
+ timer tns-alive 3
+ timer tns-alive-retries 3
+ timer tsns-prov 3
+ timer tsns-size-retries 3
+ timer tsns-config-retries 3
+ bind udp local
+  listen 127.0.0.1 23000
+  accept-ipaccess
diff --git a/ns/regen_makefile.sh b/ns/regen_makefile.sh
new file mode 100755
index 0000000..dc96587
--- /dev/null
+++ b/ns/regen_makefile.sh
@@ -0,0 +1,9 @@
+#!/bin/bash
+
+FILES="*.ttcn *.ttcnpp BSSGP_EncDec.cc IPL4asp_PT.cc IPL4asp_discovery.cc TCCConversion.cc TCCInterface.cc NS_CodecPort_CtrlFunctDef.cc UD_PT.cc RLCMAC_EncDec.cc LLC_EncDec.cc TELNETasp_PT.cc Native_FunctionDefs.cc StatsD_CodecPort_CtrlFunctdef.cc "
+
+FILES+="AF_PACKET_PT.cc AF_PACKET_PT.hh "
+
+export CPPFLAGS_TTCN3="-DBSSGP_EM_L3 -DNS_EMULATION_FR"
+
+../regen-makefile.sh NS_Tests.ttcn $FILES

-- 
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/22091
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: Ic619a374b88879d3116f8f28afb14401c3e3192b
Gerrit-Change-Number: 22091
Gerrit-PatchSet: 1
Gerrit-Owner: lynxis lazus <lynxis at fe80.eu>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210111/6de19e0e/attachment.htm>


More information about the gerrit-log mailing list