aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/tests/vty_test_runner.py
diff options
context:
space:
mode:
authorHolger Hans Peter Freyther <holger@moiji-mobile.com>2015-04-23 20:25:17 -0400
committerHolger Hans Peter Freyther <holger@moiji-mobile.com>2015-04-23 20:27:30 -0400
commit7f100c9712de5c684462e809bf31a58c0c326337 (patch)
treea0679413f21ddea3c2656f0463595056f4769989 /openbsc/tests/vty_test_runner.py
parentd4b03187c68c6136192f7a41335982b5ceeeb036 (diff)
nat: Make mode-set patching optional
Diffstat (limited to 'openbsc/tests/vty_test_runner.py')
-rw-r--r--openbsc/tests/vty_test_runner.py17
1 files changed, 17 insertions, 0 deletions
diff --git a/openbsc/tests/vty_test_runner.py b/openbsc/tests/vty_test_runner.py
index fb4ca7d1a..3581b67c9 100644
--- a/openbsc/tests/vty_test_runner.py
+++ b/openbsc/tests/vty_test_runner.py
@@ -588,6 +588,23 @@ class TestVTYNAT(TestVTYGenericBSC):
res = self.vty.command("number-rewrite rewrite.cfg")
res = self.vty.command("no number-rewrite")
+ def testEnsureNoEnsureModeSet(self):
+ self.vty.enable()
+ res = self.vty.command("configure terminal")
+ res = self.vty.command("nat")
+
+ # Ensure the default
+ res = self.vty.command("show running-config")
+ self.assert_(res.find('\n sdp-ensure-amr-mode-set') > 0)
+
+ self.vty.command("sdp-ensure-amr-mode-set")
+ res = self.vty.command("show running-config")
+ self.assert_(res.find('\n sdp-ensure-amr-mode-set') > 0)
+
+ self.vty.command("no sdp-ensure-amr-mode-set")
+ res = self.vty.command("show running-config")
+ self.assert_(res.find('\n no sdp-ensure-amr-mode-set') > 0)
+
def testRewritePostNoRewrite(self):
self.vty.enable()
self.vty.command("configure terminal")