Add 4o6 and 6o4 *no_odl* tests 64/4664/1
authorFilip Tehlar <ftehlar@cisco.com>
Thu, 12 Jan 2017 16:53:54 +0000 (17:53 +0100)
committerFilip Tehlar <ftehlar@cisco.com>
Thu, 12 Jan 2017 16:53:54 +0000 (17:53 +0100)
Change-Id: Idf755540e2914efc85e016f2f81b156ac19543bd
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
tests/data_plane/configs/vpp_lite_config/basic/4o6_no_odl/vpp1.config [new file with mode: 0644]
tests/data_plane/configs/vpp_lite_config/basic/4o6_no_odl/vpp2.config [new file with mode: 0644]
tests/data_plane/configs/vpp_lite_config/basic/6o4_no_odl/vpp1.config [new file with mode: 0644]
tests/data_plane/configs/vpp_lite_config/basic/6o4_no_odl/vpp2.config [new file with mode: 0644]
tests/data_plane/vpp_lite_topo/test_driver/basic_no_odl.sh
tests/data_plane/vpp_lite_topo/tests/test_basic_4o6_no_odl.sh [new file with mode: 0755]
tests/data_plane/vpp_lite_topo/tests/test_basic_6o4_no_odl.sh [new file with mode: 0755]

diff --git a/tests/data_plane/configs/vpp_lite_config/basic/4o6_no_odl/vpp1.config b/tests/data_plane/configs/vpp_lite_config/basic/4o6_no_odl/vpp1.config
new file mode 100644 (file)
index 0000000..ae119f7
--- /dev/null
@@ -0,0 +1,7 @@
+create_host_iface vpp1 6.0.1.1/24
+create_host_iface intervpp1 6:0:3::1/64
+
+lisp_state enable
+lisp_locator_set_with_locator ls1 host-intervpp1 1 1
+lisp_local_eid eid 6.0.1.0/24 locator-set ls1
+lisp_remote_mapping eid 6.0.2.0/24 rloc 6:0:3::2
diff --git a/tests/data_plane/configs/vpp_lite_config/basic/4o6_no_odl/vpp2.config b/tests/data_plane/configs/vpp_lite_config/basic/4o6_no_odl/vpp2.config
new file mode 100644 (file)
index 0000000..204d87a
--- /dev/null
@@ -0,0 +1,7 @@
+create_host_iface vpp2 6.0.2.1/24
+create_host_iface intervpp2 6:0:3::2/64
+
+lisp_state enable
+lisp_locator_set_with_locator ls1 host-intervpp2 1 1
+lisp_local_eid eid 6.0.2.0/24 locator-set ls1
+lisp_remote_mapping eid 6.0.1.0/24 rloc 6:0:3::1
diff --git a/tests/data_plane/configs/vpp_lite_config/basic/6o4_no_odl/vpp1.config b/tests/data_plane/configs/vpp_lite_config/basic/6o4_no_odl/vpp1.config
new file mode 100644 (file)
index 0000000..1b8bf7f
--- /dev/null
@@ -0,0 +1,7 @@
+create_host_iface vpp1 6:0:1::1/64
+create_host_iface intervpp1 6.0.3.1/24
+
+lisp_state enable
+lisp_locator_set_with_locator ls1 host-intervpp1 1 1
+lisp_local_eid eid 6:0:1::0/64 locator-set ls1
+lisp_remote_mapping eid 6:0:2::0/64 rloc 6.0.3.2
diff --git a/tests/data_plane/configs/vpp_lite_config/basic/6o4_no_odl/vpp2.config b/tests/data_plane/configs/vpp_lite_config/basic/6o4_no_odl/vpp2.config
new file mode 100644 (file)
index 0000000..8a62ac5
--- /dev/null
@@ -0,0 +1,7 @@
+create_host_iface vpp2 6:0:2::1/64
+create_host_iface intervpp2 6.0.3.2/24
+
+lisp_state enable
+lisp_locator_set_with_locator ls1 host-intervpp2 1 1
+lisp_local_eid eid 6:0:2::0/64 locator-set ls1
+lisp_remote_mapping eid 6:0:1::0/64 rloc 6.0.3.1
index 9996111..aab2adb 100644 (file)
@@ -33,10 +33,17 @@ function test_basic_no_odl
   echo "set int ip address del host-intervpp2 6:0:3::2/64" | nc 0 5003
   echo "set int ip address host-intervpp2 6:0:3::20/64" | nc 0 5003
 
-  echo "lisp remote-mapping del vni 0 eid 6.0.2.0/24 rloc 6.0.3.2" | nc 0 5002
-  echo "lisp remote-mapping add vni 0 eid 6.0.2.0/24 rloc 6.0.3.20" | nc 0 5002
-  echo "lisp remote-mapping del vni 0 eid 6:0:2::0/64 rloc 6:0:3::2" | nc 0 5002
-  echo "lisp remote-mapping add vni 0 eid 6:0:2::0/64 rloc 6:0:3::20" | nc 0 5002
+  if [ ${3} == "switch_rlocs" ] ; then
+    echo "lisp remote-mapping del vni 0 eid 6.0.2.0/24" | nc 0 5002
+    echo "lisp remote-mapping add vni 0 eid 6.0.2.0/24 rloc 6:0:3::20" | nc 0 5002
+    echo "lisp remote-mapping del vni 0 eid 6:0:2::0/64" | nc 0 5002
+    echo "lisp remote-mapping add vni 0 eid 6:0:2::0/64 rloc 6.0.3.20" | nc 0 5002
+  else
+    echo "lisp remote-mapping del vni 0 eid 6.0.2.0/24 rloc 6.0.3.2" | nc 0 5002
+    echo "lisp remote-mapping add vni 0 eid 6.0.2.0/24 rloc 6.0.3.20" | nc 0 5002
+    echo "lisp remote-mapping del vni 0 eid 6:0:2::0/64 rloc 6:0:3::2" | nc 0 5002
+    echo "lisp remote-mapping add vni 0 eid 6:0:2::0/64 rloc 6:0:3::20" | nc 0 5002
+  fi
 
   ip netns exec vppns1 "${1}" -w 15 -c 1 "${2}"
   rc=$?
diff --git a/tests/data_plane/vpp_lite_topo/tests/test_basic_4o6_no_odl.sh b/tests/data_plane/vpp_lite_topo/tests/test_basic_4o6_no_odl.sh
new file mode 100755 (executable)
index 0000000..3b9a23e
--- /dev/null
@@ -0,0 +1,9 @@
+#!/usr/bin/env bash
+
+# Test basic LISP functionality without odl (ip4 over ip6)
+
+VPP_LITE_CONF=`pwd`/../configs/vpp_lite_config/basic/4o6_no_odl
+
+source test_driver/basic_no_odl.sh
+
+test_basic_no_odl ping "6.0.2.2" "switch_rlocs"
diff --git a/tests/data_plane/vpp_lite_topo/tests/test_basic_6o4_no_odl.sh b/tests/data_plane/vpp_lite_topo/tests/test_basic_6o4_no_odl.sh
new file mode 100755 (executable)
index 0000000..1fb0bb2
--- /dev/null
@@ -0,0 +1,9 @@
+#!/usr/bin/env bash
+
+# Test basic LISP functionality without odl (ip6 over ip4)
+
+VPP_LITE_CONF=`pwd`/../configs/vpp_lite_config/basic/6o4_no_odl
+
+source test_driver/basic_no_odl.sh
+
+test_basic_no_odl ping6 "6:0:2::2" "switch_rlocs"