Skip to content
Snippets Groups Projects
Commit 79136d45 authored by Lluis Gifre Renom's avatar Lluis Gifre Renom
Browse files

Merge branch 'release/2.0.1' of https://labs.etsi.org/rep/tfs/controller into feat/slice-grouping

parents cb0be974 4fed2234
No related branches found
No related tags found
2 merge requests!142Release TeraFlowSDN 2.1,!64Slice Grouping
...@@ -69,6 +69,8 @@ def main(): ...@@ -69,6 +69,8 @@ def main():
wait_for_environment_variables([ wait_for_environment_variables([
get_env_var_name(ServiceNameEnum.CONTEXT, ENVVAR_SUFIX_SERVICE_HOST ), get_env_var_name(ServiceNameEnum.CONTEXT, ENVVAR_SUFIX_SERVICE_HOST ),
get_env_var_name(ServiceNameEnum.CONTEXT, ENVVAR_SUFIX_SERVICE_PORT_GRPC), get_env_var_name(ServiceNameEnum.CONTEXT, ENVVAR_SUFIX_SERVICE_PORT_GRPC),
get_env_var_name(ServiceNameEnum.DEVICE, ENVVAR_SUFIX_SERVICE_HOST ),
get_env_var_name(ServiceNameEnum.DEVICE, ENVVAR_SUFIX_SERVICE_PORT_GRPC),
]) ])
signal.signal(signal.SIGINT, signal_handler) signal.signal(signal.SIGINT, signal_handler)
......
...@@ -106,8 +106,6 @@ def test_devices_bootstraping( ...@@ -106,8 +106,6 @@ def test_devices_bootstraping(
link_uuid = link['link_id']['link_uuid']['uuid'] link_uuid = link['link_id']['link_uuid']['uuid']
LOGGER.info('Adding Link {:s}'.format(link_uuid)) LOGGER.info('Adding Link {:s}'.format(link_uuid))
response = context_client.SetLink(Link(**link)) response = context_client.SetLink(Link(**link))
assert response.name == link_uuid
context_client.SetLink(Link(**link))
def test_devices_bootstrapped(context_client : ContextClient): # pylint: disable=redefined-outer-name def test_devices_bootstrapped(context_client : ContextClient): # pylint: disable=redefined-outer-name
# ----- List entities - Ensure bevices are created ----------------------------------------------------------------- # ----- List entities - Ensure bevices are created -----------------------------------------------------------------
......
...@@ -58,7 +58,6 @@ def test_scenario_cleanup( ...@@ -58,7 +58,6 @@ def test_scenario_cleanup(
device_uuid = device_id['device_uuid']['uuid'] device_uuid = device_id['device_uuid']['uuid']
LOGGER.info('Deleting Device {:s}'.format(device_uuid)) LOGGER.info('Deleting Device {:s}'.format(device_uuid))
device_client.DeleteDevice(DeviceId(**device_id)) device_client.DeleteDevice(DeviceId(**device_id))
#expected_events.append(('DeviceEvent', EVENT_REMOVE, json_device_id(device_uuid)))
response = context_client.ListDevices(Empty()) response = context_client.ListDevices(Empty())
assert len(response.devices) == 0 assert len(response.devices) == 0
...@@ -72,7 +71,6 @@ def test_scenario_cleanup( ...@@ -72,7 +71,6 @@ def test_scenario_cleanup(
LOGGER.info('Deleting Topology {:s}/{:s}'.format(context_uuid, topology_uuid)) LOGGER.info('Deleting Topology {:s}/{:s}'.format(context_uuid, topology_uuid))
context_client.RemoveTopology(TopologyId(**topology_id)) context_client.RemoveTopology(TopologyId(**topology_id))
context_id = json_context_id(context_uuid) context_id = json_context_id(context_uuid)
#expected_events.append(('TopologyEvent', EVENT_REMOVE, json_topology_id(topology_uuid, context_id=context_id)))
# ----- Delete Contexts and Validate Collected Events -------------------------------------------------------------- # ----- Delete Contexts and Validate Collected Events --------------------------------------------------------------
for context in CONTEXTS: for context in CONTEXTS:
...@@ -80,4 +78,3 @@ def test_scenario_cleanup( ...@@ -80,4 +78,3 @@ def test_scenario_cleanup(
context_uuid = context_id['context_uuid']['uuid'] context_uuid = context_id['context_uuid']['uuid']
LOGGER.info('Deleting Context {:s}'.format(context_uuid)) LOGGER.info('Deleting Context {:s}'.format(context_uuid))
context_client.RemoveContext(ContextId(**context_id)) context_client.RemoveContext(ContextId(**context_id))
#expected_events.append(('ContextEvent', EVENT_REMOVE, json_context_id(context_uuid)))
...@@ -54,15 +54,6 @@ def service_client(): ...@@ -54,15 +54,6 @@ def service_client():
def test_rules_entry( def test_rules_entry(
context_client : ContextClient, device_client : DeviceClient, service_client : ServiceClient): # pylint: disable=redefined-outer-name context_client : ContextClient, device_client : DeviceClient, service_client : ServiceClient): # pylint: disable=redefined-outer-name
# for device, _, __ in DEVICES:
# # Enable device
# device_p4_with_operational_status = copy.deepcopy(device)
# device_p4_with_operational_status['device_operational_status'] = \
# DeviceOperationalStatusEnum.DEVICEOPERATIONALSTATUS_ENABLED
# device_client.ConfigureDevice(Device(**device_p4_with_operational_status))
# ----- Create Services --------------------------------------------------------------- # ----- Create Services ---------------------------------------------------------------
for service, endpoints in SERVICES: for service, endpoints in SERVICES:
# Insert Service (table entries) # Insert Service (table entries)
...@@ -71,4 +62,4 @@ def test_rules_entry( ...@@ -71,4 +62,4 @@ def test_rules_entry(
service_p4 = copy.deepcopy(service) service_p4 = copy.deepcopy(service)
service_client.CreateService(Service(**service_p4)) service_client.CreateService(Service(**service_p4))
service_p4['service_endpoint_ids'].extend(endpoints) service_p4['service_endpoint_ids'].extend(endpoints)
service_client.UpdateService(Service(**service_p4)) service_client.UpdateService(Service(**service_p4))
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment