summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorJustin Pettit <jpettit@ovn.org>2016-05-17 06:39:46 -0700
committerJustin Pettit <jpettit@ovn.org>2016-06-10 16:17:46 -0700
commitfa2a27b294da84a29f1f6b41113300abff263f86 (patch)
treecff69029c3468d2105e414be99d86521524e8e32 /tests
parent9e89174086dea1090153cb5c4821dc2972604434 (diff)
downloadopenvswitch-fa2a27b294da84a29f1f6b41113300abff263f86.tar.gz
ovn-nbctl: Update basic router commands.
A few minor changes related to router commands: - Use "lr" instead of "lrouter" to be more consistent with later changes. - Use the commands where possible in ovn unit tests. - Move documentation to group router commands together. - Update references from "lrouter" to "router". Signed-off-by: Justin Pettit <jpettit@ovn.org> Acked-by: Ben Pfaff <blp@ovn.org> Acked-by: Ryan Moats <rmoats@us.ibm.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/ovn-nbctl.at56
-rw-r--r--tests/ovn.at20
2 files changed, 38 insertions, 38 deletions
diff --git a/tests/ovn-nbctl.at b/tests/ovn-nbctl.at
index faedf25d7..50d2723c0 100644
--- a/tests/ovn-nbctl.at
+++ b/tests/ovn-nbctl.at
@@ -234,56 +234,56 @@ AT_CLEANUP
dnl ---------------------------------------------------------------------
-AT_SETUP([ovn-nbctl - basic lrouter commands])
+AT_SETUP([ovn-nbctl - basic logical router commands])
OVN_NBCTL_TEST_START
-AT_CHECK([ovn-nbctl lrouter-add lr0])
-AT_CHECK([ovn-nbctl lrouter-list | ${PERL} $srcdir/uuidfilt.pl], [0], [dnl
+AT_CHECK([ovn-nbctl lr-add lr0])
+AT_CHECK([ovn-nbctl lr-list | ${PERL} $srcdir/uuidfilt.pl], [0], [dnl
<0> (lr0)
])
-AT_CHECK([ovn-nbctl lrouter-add lr1])
-AT_CHECK([ovn-nbctl lrouter-list | ${PERL} $srcdir/uuidfilt.pl], [0], [dnl
+AT_CHECK([ovn-nbctl lr-add lr1])
+AT_CHECK([ovn-nbctl lr-list | ${PERL} $srcdir/uuidfilt.pl], [0], [dnl
<0> (lr0)
<1> (lr1)
])
-AT_CHECK([ovn-nbctl lrouter-del lr0])
-AT_CHECK([ovn-nbctl lrouter-list | ${PERL} $srcdir/uuidfilt.pl], [0], [dnl
+AT_CHECK([ovn-nbctl lr-del lr0])
+AT_CHECK([ovn-nbctl lr-list | ${PERL} $srcdir/uuidfilt.pl], [0], [dnl
<0> (lr1)
])
AT_CHECK([ovn-nbctl show lr0])
-AT_CHECK([ovn-nbctl lrouter-add lr0])
+AT_CHECK([ovn-nbctl lr-add lr0])
AT_CHECK([ovn-nbctl show lr0 | ${PERL} $srcdir/uuidfilt.pl], [0],
- [ lrouter <0> (lr0)
+ [ router <0> (lr0)
])
-AT_CHECK([ovn-nbctl lrouter-add lr0], [1], [],
- [ovn-nbctl: lr0: an lrouter with this name already exists
+AT_CHECK([ovn-nbctl lr-add lr0], [1], [],
+ [ovn-nbctl: lr0: a router with this name already exists
])
-AT_CHECK([ovn-nbctl --may-exist lrouter-add lr0])
+AT_CHECK([ovn-nbctl --may-exist lr-add lr0])
AT_CHECK([ovn-nbctl show lr0 | ${PERL} $srcdir/uuidfilt.pl], [0],
- [ lrouter <0> (lr0)
+ [ router <0> (lr0)
])
-AT_CHECK([ovn-nbctl --add-duplicate lrouter-add lr0])
-AT_CHECK([ovn-nbctl --may-exist --add-duplicate lrouter-add lr0], [1], [],
+AT_CHECK([ovn-nbctl --add-duplicate lr-add lr0])
+AT_CHECK([ovn-nbctl --may-exist --add-duplicate lr-add lr0], [1], [],
[ovn-nbctl: --may-exist and --add-duplicate may not be used together
])
-AT_CHECK([ovn-nbctl lrouter-del lr0], [1], [],
+AT_CHECK([ovn-nbctl lr-del lr0], [1], [],
[ovn-nbctl: Multiple logical routers named 'lr0'. Use a UUID.
])
-AT_CHECK([ovn-nbctl lrouter-del lr2], [1], [],
- [ovn-nbctl: lr2: lrouter name not found
+AT_CHECK([ovn-nbctl lr-del lr2], [1], [],
+ [ovn-nbctl: lr2: router name not found
])
-AT_CHECK([ovn-nbctl --if-exists lrouter-del lr2])
+AT_CHECK([ovn-nbctl --if-exists lr-del lr2])
-AT_CHECK([ovn-nbctl lrouter-add])
-AT_CHECK([ovn-nbctl lrouter-add])
-AT_CHECK([ovn-nbctl --add-duplicate lrouter-add], [1], [],
+AT_CHECK([ovn-nbctl lr-add])
+AT_CHECK([ovn-nbctl lr-add])
+AT_CHECK([ovn-nbctl --add-duplicate lr-add], [1], [],
[ovn-nbctl: --add-duplicate requires specifying a name
])
-AT_CHECK([ovn-nbctl --may-exist lrouter-add], [1], [],
+AT_CHECK([ovn-nbctl --may-exist lr-add], [1], [],
[ovn-nbctl: --may-exist requires specifying a name
])
@@ -295,7 +295,7 @@ dnl ---------------------------------------------------------------------
AT_SETUP([ovn-nbctl - basic lrport commands])
OVN_NBCTL_TEST_START
-AT_CHECK([ovn-nbctl lrouter-add lr0])
+AT_CHECK([ovn-nbctl lr-add lr0])
AT_CHECK([ovn-nbctl lrport-add lr0 lrp0])
AT_CHECK([ovn-nbctl lrport-add lr0 lrp0], [1], [],
[ovn-nbctl: lrp0: an lrport with this name already exists
@@ -311,12 +311,12 @@ AT_CHECK([ovn-nbctl lrport-list lr0 | ${PERL} $srcdir/uuidfilt.pl], [0], [dnl
<1> (lrp1)
])
-AT_CHECK([ovn-nbctl lrouter-add lr1])
+AT_CHECK([ovn-nbctl lr-add lr1])
AT_CHECK([ovn-nbctl lrport-add lr0 lrp1], [1], [],
[ovn-nbctl: lrp1: an lrport with this name already exists
])
AT_CHECK([ovn-nbctl --may-exist lrport-add lr1 lrp1], [1], [],
- [ovn-nbctl: lrp1: lrport already exists but in lrouter lr0
+ [ovn-nbctl: lrp1: lrport already exists but in router lr0
])
AT_CHECK([ovn-nbctl lrport-del lrp1])
@@ -332,7 +332,7 @@ dnl ---------------------------------------------------------------------
AT_SETUP([ovn-nbctl - lrport addresses])
OVN_NBCTL_TEST_START
-AT_CHECK([ovn-nbctl lrouter-add lr0])
+AT_CHECK([ovn-nbctl lr-add lr0])
AT_CHECK([ovn-nbctl lrport-add lr0 lrp0])
AT_CHECK([ovn-nbctl lrport-get-mac-address lrp0], [0], [
])
@@ -353,7 +353,7 @@ dnl ---------------------------------------------------------------------
AT_SETUP([ovn-nbctl - lrport enable and disable])
OVN_NBCTL_TEST_START
-AT_CHECK([ovn-nbctl lrouter-add lr0])
+AT_CHECK([ovn-nbctl lr-add lr0])
AT_CHECK([ovn-nbctl lrport-add lr0 lrp0])
AT_CHECK([ovn-nbctl lrport-get-enabled lrp0], [0], [enabled
])
diff --git a/tests/ovn.at b/tests/ovn.at
index 633cf359a..af92904f1 100644
--- a/tests/ovn.at
+++ b/tests/ovn.at
@@ -1263,7 +1263,7 @@ for i in 1 2 3; do
done
done
-ovn-nbctl create Logical_Router name=lr0
+ovn-nbctl lr-add lr0
for i in 1 2 3; do
for j in 1 2 3; do
lrp_uuid=`ovn-nbctl \
@@ -2077,8 +2077,8 @@ ovn_start
# network. R1 has a switchs ls1 (191.168.1.0/24) connected to it.
# R2 has ls2 (172.16.1.0/24) connected to it.
-ovn-nbctl create Logical_Router name=R1
-ovn-nbctl create Logical_Router name=R2
+ovn-nbctl lr-add R1
+ovn-nbctl lr-add R2
ovn-nbctl lswitch-add ls1
ovn-nbctl lswitch-add ls2
@@ -2234,7 +2234,7 @@ ovn_start
# One LR - R1 has switch ls1 (191.168.1.0/24) connected to it,
# and has switch ls2 (172.16.1.0/24) connected to it.
-ovn-nbctl create Logical_Router name=R1
+ovn-nbctl lr-add R1
ovn-nbctl lswitch-add ls1
ovn-nbctl lswitch-add ls2
@@ -2377,8 +2377,8 @@ ovn_start
# connected to it.
# R2 has alice (172.16.1.0/24) and bob (172.16.2.0/24) connected to it.
-ovn-nbctl create Logical_Router name=R1
-ovn-nbctl create Logical_Router name=R2
+ovn-nbctl lr-add R1
+ovn-nbctl lr-add R2
ovn-nbctl lswitch-add foo
ovn-nbctl lswitch-add alice
@@ -2645,9 +2645,9 @@ ovn_start
# connected to it. R2 has alice (172.16.1.0/24) and R3 has bob (10.32.1.0/24)
# connected to it.
-ovn-nbctl create Logical_Router name=R1
-ovn-nbctl create Logical_Router name=R2
-ovn-nbctl create Logical_Router name=R3
+ovn-nbctl lr-add R1
+ovn-nbctl lr-add R2
+ovn-nbctl lr-add R3
ovn-nbctl lswitch-add foo
ovn-nbctl lswitch-add alice
@@ -3064,7 +3064,7 @@ ovn_start
# One LR - R1 has switch ls1 (191.168.1.0/24) connected to it,
# and has switch ls2 (172.16.1.0/24) connected to it.
-ovn-nbctl create Logical_Router name=R1
+ovn-nbctl lr-add R1
ovn-nbctl lswitch-add ls1
ovn-nbctl lswitch-add ls2