neels has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-hnbgw/+/35643?usp=email )
Change subject: add tests/pfcp_cfg.vty.with_pfcp ......................................................................
add tests/pfcp_cfg.vty.with_pfcp
So far, we had no pfcp.vty test, because PFCP support is built conditionally, and the pfcp.vty test would always fail without PFCP support.
Add a pfcp test for the VTY, conditionally: use suffix .vty.with_pfcp to identify tests that need PFCP support, and run those only when configured with --enable-pfcp.
Related: SYS#5895 Change-Id: Ibb1797bb43a18f26fc693e0c8920cfd1f5fb9ede --- M tests/Makefile.am A tests/pfcp_cfg.vty.with_pfcp 2 files changed, 78 insertions(+), 0 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-hnbgw refs/changes/43/35643/1
diff --git a/tests/Makefile.am b/tests/Makefile.am index d499c33..f8b109d 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -29,6 +29,7 @@ $(srcdir)/*.ctrl \ $(srcdir)/config/*.cfg \ $(srcdir)/config/*.vty \ + $(srcdir)/config/*.vty.with_pfcp \ $(srcdir)/config/run_tests.sh \ $(NULL)
@@ -50,7 +51,11 @@ endif
# Run a specific test with: 'make vty-test VTY_TEST=osmo-hnbgw.vty' +if ENABLE_PFCP +VTY_TEST ?= *.vty* +else VTY_TEST ?= *.vty +endif
# To update the VTY script from current application behavior, # pass -u to vty_script_runner.py by doing: diff --git a/tests/pfcp_cfg.vty.with_pfcp b/tests/pfcp_cfg.vty.with_pfcp new file mode 100644 index 0000000..a093ffb --- /dev/null +++ b/tests/pfcp_cfg.vty.with_pfcp @@ -0,0 +1,55 @@ +OsmoHNBGW> enable +OsmoHNBGW# configure terminal + +OsmoHNBGW(config)# hnbgw +OsmoHNBGW(config-hnbgw)# list +... + pfcp +... +OsmoHNBGW(config-hnbgw)# pfcp? + pfcp Configure PFCP for GTP tunnel mapping + +OsmoHNBGW(config-hnbgw)# pfcp +OsmoHNBGW(config-hnbgw-pfcp)# list +... + local-addr IP_ADDR + local-port <1-65535> + remote-addr IP_ADDR + +OsmoHNBGW(config-hnbgw-pfcp)# local-addr? + local-addr Local address for PFCP +OsmoHNBGW(config-hnbgw-pfcp)# local-addr ? + IP_ADDR IP address + +OsmoHNBGW(config-hnbgw-pfcp)# local-port? + local-port Local port for PFCP +OsmoHNBGW(config-hnbgw-pfcp)# local-port ? + <1-65535> UDP port + +OsmoHNBGW(config-hnbgw-pfcp)# remote-addr? + remote-addr Remote UPF's listen IP address; where to send PFCP requests +OsmoHNBGW(config-hnbgw-pfcp)# remote-addr ? + IP_ADDR IP address + + +OsmoHNBGW(config-hnbgw-pfcp)# show running-config +... +hnbgw +... + pfcp +msc 0 +... + +OsmoHNBGW(config-hnbgw-pfcp)# remote-addr 127.0.0.2 +OsmoHNBGW(config-hnbgw-pfcp)# local-addr 127.0.0.1 +OsmoHNBGW(config-hnbgw-pfcp)# local-port 8805 + +OsmoHNBGW(config-hnbgw-pfcp)# show running-config +... +hnbgw +... + pfcp + local-addr 127.0.0.1 + remote-addr 127.0.0.2 +msc 0 +...