aboutsummaryrefslogtreecommitdiffstats
path: root/tests/unit/network_services/helpers
diff options
context:
space:
mode:
authorRoss Brattain <ross.b.brattain@intel.com>2017-09-12 09:57:38 -0700
committerRoss Brattain <ross.b.brattain@intel.com>2017-09-19 07:42:43 -0700
commit9b0b8ae33541c0ad8925521b1c3f1bc559fefbe6 (patch)
tree24c3e5279786bd0ccf9816e9d1076d067b6cee43 /tests/unit/network_services/helpers
parent51ecde958cbaaedcb443bd7845eb1da9a1c013af (diff)
NSB: count from 0, vnf_0, tg_9, private->uplink, public->downlink
Also rename private to uplink, public to downlink for scale-out template we need to count from 0 so we can use range() without +1/-1 errors vnf_0, vnf_1 tg_0, tg_1 also fix Ixia defaults Change-Id: I6aecfbb95f99af20f012a9df19c19be77d1b5b77 Signed-off-by: Ross Brattain <ross.b.brattain@intel.com> Signed-off-by: Edward MacGillivray <edward.s.macgillivray@intel.com>
Diffstat (limited to 'tests/unit/network_services/helpers')
-rw-r--r--tests/unit/network_services/helpers/acl_vnf_topology_ixia.yaml4
-rw-r--r--tests/unit/network_services/helpers/test_samplevnf_helper.py14
2 files changed, 9 insertions, 9 deletions
diff --git a/tests/unit/network_services/helpers/acl_vnf_topology_ixia.yaml b/tests/unit/network_services/helpers/acl_vnf_topology_ixia.yaml
index 606d557e9..f60834fbd 100644
--- a/tests/unit/network_services/helpers/acl_vnf_topology_ixia.yaml
+++ b/tests/unit/network_services/helpers/acl_vnf_topology_ixia.yaml
@@ -27,7 +27,7 @@ nsd:nsd-catalog:
VNF model: ../../vnf_descriptors/acl_vnf.yaml
vld:
- - id: private_1
+ - id: uplink_1
name: tg__1 to vnf__1 link 1
type: ELAN
vnfd-connection-point-ref:
@@ -38,7 +38,7 @@ nsd:nsd-catalog:
vnfd-connection-point-ref: xe0
vnfd-id-ref: vnf__1 #VNF
- - id: public_1
+ - id: downlink_1
name: vnf__1 to tg__1 link 2
type: ELAN
vnfd-connection-point-ref:
diff --git a/tests/unit/network_services/helpers/test_samplevnf_helper.py b/tests/unit/network_services/helpers/test_samplevnf_helper.py
index 3d3f6dc28..0ac363f28 100644
--- a/tests/unit/network_services/helpers/test_samplevnf_helper.py
+++ b/tests/unit/network_services/helpers/test_samplevnf_helper.py
@@ -37,7 +37,7 @@ class TestPortPairs(unittest.TestCase):
vnfd = TestMultiPortConfig.VNFD['vnfd:vnfd-catalog']['vnfd'][0]
interfaces = vnfd['vdu'][0]['external-interface']
port_pairs = PortPairs(interfaces)
- self.assertEqual(port_pairs.valid_networks, [("private_0", "public_0")])
+ self.assertEqual(port_pairs.valid_networks, [("uplink_0", "downlink_0")])
def test_all_ports(self):
vnfd = TestMultiPortConfig.VNFD['vnfd:vnfd-catalog']['vnfd'][0]
@@ -45,17 +45,17 @@ class TestPortPairs(unittest.TestCase):
port_pairs = PortPairs(interfaces)
self.assertEqual(set(port_pairs.all_ports), {"xe0", "xe1"})
- def test_priv_ports(self):
+ def test_uplink_ports(self):
vnfd = TestMultiPortConfig.VNFD['vnfd:vnfd-catalog']['vnfd'][0]
interfaces = vnfd['vdu'][0]['external-interface']
port_pairs = PortPairs(interfaces)
- self.assertEqual(port_pairs.priv_ports, ["xe0"])
+ self.assertEqual(port_pairs.uplink_ports, ["xe0"])
- def test_pub_ports(self):
+ def test_downlink_ports(self):
vnfd = TestMultiPortConfig.VNFD['vnfd:vnfd-catalog']['vnfd'][0]
interfaces = vnfd['vdu'][0]['external-interface']
port_pairs = PortPairs(interfaces)
- self.assertEqual(port_pairs.pub_ports, ["xe1"])
+ self.assertEqual(port_pairs.downlink_ports, ["xe1"])
class TestMultiPortConfig(unittest.TestCase):
@@ -99,7 +99,7 @@ class TestMultiPortConfig(unittest.TestCase):
'ifname': 'xe0',
'local_iface_name': 'eth0',
'local_mac': '00:00:00:00:00:02',
- 'vld_id': 'private_0',
+ 'vld_id': 'uplink_0',
},
'vnfd-connection-point-ref': 'xe0',
'name': 'xe0'},
@@ -117,7 +117,7 @@ class TestMultiPortConfig(unittest.TestCase):
'ifname': 'xe1',
'local_iface_name': 'eth1',
'local_mac': '00:00:00:00:00:01',
- 'vld_id': 'public_0',
+ 'vld_id': 'downlink_0',
},
'vnfd-connection-point-ref': 'xe1',
'name': 'xe1'}