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

Merge branch 'develop' of ssh://gifrerenom_labs.etsi.org/tfs/controller into...

Merge branch 'develop' of ssh://gifrerenom_labs.etsi.org/tfs/controller into feat/233-cttc-fix-ci-cd-pipeline-end-to-end-tests-not-passing
parents 43810bea 5cf273cc
No related branches found
No related tags found
2 merge requests!359Release TeraFlowSDN 5.0,!299Resolve "(CTTC) Fix CI/CD pipeline end-to-end tests not passing"
...@@ -32,6 +32,8 @@ class _Driver: ...@@ -32,6 +32,8 @@ class _Driver:
def __init__(self, name : str, address: str, port: int, **settings) -> None: def __init__(self, name : str, address: str, port: int, **settings) -> None:
""" Initialize Driver. """ Initialize Driver.
Parameters: Parameters:
name : str
Device driver name
address : str address : str
The address of the device The address of the device
port : int port : int
......
...@@ -22,6 +22,8 @@ from common.tools.grpc.Tools import grpc_message_to_json_string ...@@ -22,6 +22,8 @@ from common.tools.grpc.Tools import grpc_message_to_json_string
DEVICE_TYPE_TO_DEEPNESS = { DEVICE_TYPE_TO_DEEPNESS = {
DeviceTypeEnum.EMULATED_DATACENTER.value : 90, DeviceTypeEnum.EMULATED_DATACENTER.value : 90,
DeviceTypeEnum.DATACENTER.value : 90, DeviceTypeEnum.DATACENTER.value : 90,
DeviceTypeEnum.EMULATED_CLIENT.value : 90,
DeviceTypeEnum.CLIENT.value : 90,
DeviceTypeEnum.TERAFLOWSDN_CONTROLLER.value : 80, DeviceTypeEnum.TERAFLOWSDN_CONTROLLER.value : 80,
DeviceTypeEnum.EMULATED_IP_SDN_CONTROLLER.value : 80, DeviceTypeEnum.EMULATED_IP_SDN_CONTROLLER.value : 80,
...@@ -50,6 +52,8 @@ DEVICE_TYPE_TO_DEEPNESS = { ...@@ -50,6 +52,8 @@ DEVICE_TYPE_TO_DEEPNESS = {
DeviceTypeEnum.OPTICAL_TRANSPONDER.value : 10, DeviceTypeEnum.OPTICAL_TRANSPONDER.value : 10,
DeviceTypeEnum.EMULATED_OPTICAL_ROADM.value : 10, DeviceTypeEnum.EMULATED_OPTICAL_ROADM.value : 10,
DeviceTypeEnum.OPTICAL_ROADM.value : 10, DeviceTypeEnum.OPTICAL_ROADM.value : 10,
DeviceTypeEnum.QKD_NODE.value : 10,
DeviceTypeEnum.OPEN_ROADM.value : 10,
DeviceTypeEnum.EMULATED_OPTICAL_SPLITTER.value : 0, DeviceTypeEnum.EMULATED_OPTICAL_SPLITTER.value : 0,
DeviceTypeEnum.NETWORK.value : 0, # network out of our control; always delegate DeviceTypeEnum.NETWORK.value : 0, # network out of our control; always delegate
......
...@@ -13,18 +13,12 @@ ...@@ -13,18 +13,12 @@
# limitations under the License. # limitations under the License.
import os import os
from typing import Dict, List, Tuple
from common.Constants import DEFAULT_CONTEXT_NAME, DEFAULT_TOPOLOGY_NAME from common.Constants import DEFAULT_CONTEXT_NAME, DEFAULT_TOPOLOGY_NAME
from common.tools.object_factory.Context import json_context, json_context_id from common.tools.object_factory.Context import json_context, json_context_id
from common.tools.object_factory.Device import ( from common.tools.object_factory.Device import (
json_device_connect_rules, json_device_emulated_connect_rules, json_device_emulated_packet_router_disabled, json_device_connect_rules, json_device_id, json_device_p4_disabled)
json_device_connect_rules, json_device_id, json_device_p4_disabled, from common.tools.object_factory.Service import get_service_uuid, json_service_p4_planned
json_device_emulated_tapi_disabled, json_device_id, json_device_packetrouter_disabled, json_device_tapi_disabled) from common.tools.object_factory.EndPoint import json_endpoint_ids, json_endpoints
from common.tools.object_factory.Service import (
get_service_uuid, json_service_l3nm_planned,json_service_p4_planned)
from common.tools.object_factory.ConfigRule import (
json_config_rule_set, json_config_rule_delete)
from common.tools.object_factory.EndPoint import json_endpoint, json_endpoint_ids, json_endpoints, json_endpoint_id
from common.tools.object_factory.EndPoint import json_endpoint_descriptor from common.tools.object_factory.EndPoint import json_endpoint_descriptor
from common.tools.object_factory.Link import get_link_uuid, json_link, json_link_id from common.tools.object_factory.Link import get_link_uuid, json_link, json_link_id
from common.tools.object_factory.Topology import json_topology, json_topology_id from common.tools.object_factory.Topology import json_topology, json_topology_id
......
...@@ -14,14 +14,9 @@ ...@@ -14,14 +14,9 @@
import copy, logging, pytest import copy, logging, pytest
from common.Settings import get_setting from common.Settings import get_setting
from common.tests.EventTools import EVENT_CREATE, EVENT_UPDATE, check_events
from common.tools.object_factory.Context import json_context_id from common.tools.object_factory.Context import json_context_id
from common.tools.object_factory.Device import json_device_id
from common.tools.object_factory.Link import json_link_id
from common.tools.object_factory.Topology import json_topology_id
from context.client.ContextClient import ContextClient from context.client.ContextClient import ContextClient
from context.client.EventsCollector import EventsCollector from common.proto.context_pb2 import Context, ContextId, Device, Empty, Link, Topology, DeviceOperationalStatusEnum
from common.proto.context_pb2 import ConfigActionEnum, Context, ContextId, Device, Empty, Link, Topology, DeviceOperationalStatusEnum
from device.client.DeviceClient import DeviceClient from device.client.DeviceClient import DeviceClient
from .Objects import CONTEXT_ID, CONTEXTS, DEVICES, LINKS, TOPOLOGIES from .Objects import CONTEXT_ID, CONTEXTS, DEVICES, LINKS, TOPOLOGIES
......
...@@ -12,18 +12,13 @@ ...@@ -12,18 +12,13 @@
# See the License for the specific language governing permissions and # See the License for the specific language governing permissions and
# limitations under the License. # limitations under the License.
import copy, logging, pytest import logging, pytest
from common.Settings import get_setting from common.Settings import get_setting
from common.tests.EventTools import EVENT_REMOVE, check_events
from common.tools.object_factory.Context import json_context_id from common.tools.object_factory.Context import json_context_id
from common.tools.object_factory.Device import json_device_id
from common.tools.object_factory.Link import json_link_id
from common.tools.object_factory.Topology import json_topology_id
from context.client.ContextClient import ContextClient from context.client.ContextClient import ContextClient
from context.client.EventsCollector import EventsCollector from common.proto.context_pb2 import ContextId, DeviceId, Empty, LinkId, TopologyId
from common.proto.context_pb2 import ConfigActionEnum, ContextId, Device, DeviceId, Empty, Link, LinkId, TopologyId, DeviceOperationalStatusEnum
from device.client.DeviceClient import DeviceClient from device.client.DeviceClient import DeviceClient
from .Objects import CONTEXT_ID, CONTEXTS, DEVICES, LINKS, TOPOLOGIES from .Objects import CONTEXTS, DEVICES, LINKS, TOPOLOGIES
LOGGER = logging.getLogger(__name__) LOGGER = logging.getLogger(__name__)
LOGGER.setLevel(logging.DEBUG) LOGGER.setLevel(logging.DEBUG)
......
...@@ -14,24 +14,16 @@ ...@@ -14,24 +14,16 @@
import copy, logging, pytest import copy, logging, pytest
from common.Settings import get_setting from common.Settings import get_setting
from common.tests.EventTools import EVENT_CREATE, EVENT_UPDATE, check_events
from common.tools.object_factory.Context import json_context_id
from common.tools.object_factory.Device import json_device_id
from common.tools.object_factory.Service import json_service_id
from common.tools.object_factory.Link import json_link_id
from common.tools.object_factory.Topology import json_topology_id
from context.client.ContextClient import ContextClient from context.client.ContextClient import ContextClient
from context.client.EventsCollector import EventsCollector from common.proto.context_pb2 import Service
from common.proto.context_pb2 import Context, ContextId, Device, Empty, Link, Topology, Service, ServiceId
from device.client.DeviceClient import DeviceClient from device.client.DeviceClient import DeviceClient
from service.client.ServiceClient import ServiceClient from service.client.ServiceClient import ServiceClient
from tests.p4.tests.Objects import CONTEXT_ID, CONTEXTS, DEVICES, LINKS, TOPOLOGIES, SERVICES from tests.p4.tests.Objects import SERVICES
from common.proto.context_pb2 import ConfigActionEnum, Device, DeviceId,\
DeviceOperationalStatusEnum
LOGGER = logging.getLogger(__name__) LOGGER = logging.getLogger(__name__)
LOGGER.setLevel(logging.DEBUG) LOGGER.setLevel(logging.DEBUG)
@pytest.fixture(scope='session') @pytest.fixture(scope='session')
def context_client(): def context_client():
_client = ContextClient(get_setting('CONTEXTSERVICE_SERVICE_HOST'), get_setting('CONTEXTSERVICE_SERVICE_PORT_GRPC')) _client = ContextClient(get_setting('CONTEXTSERVICE_SERVICE_HOST'), get_setting('CONTEXTSERVICE_SERVICE_PORT_GRPC'))
......
...@@ -14,18 +14,12 @@ ...@@ -14,18 +14,12 @@
import copy, logging, pytest import copy, logging, pytest
from common.Settings import get_setting from common.Settings import get_setting
from common.tests.EventTools import EVENT_REMOVE, check_events
from common.tools.object_factory.Context import json_context_id
from common.tools.object_factory.Device import json_device_id
from common.tools.object_factory.Service import json_service_id from common.tools.object_factory.Service import json_service_id
from common.tools.object_factory.Link import json_link_id
from common.tools.object_factory.Topology import json_topology_id
from context.client.ContextClient import ContextClient from context.client.ContextClient import ContextClient
from context.client.EventsCollector import EventsCollector from common.proto.context_pb2 import ServiceId
from common.proto.context_pb2 import ConfigActionEnum, ContextId, Device, DeviceId, Empty, LinkId, TopologyId, Service, ServiceId, DeviceOperationalStatusEnum
from device.client.DeviceClient import DeviceClient from device.client.DeviceClient import DeviceClient
from service.client.ServiceClient import ServiceClient from service.client.ServiceClient import ServiceClient
from .Objects import CONTEXT_ID, CONTEXTS, DEVICES, LINKS, TOPOLOGIES, SERVICES from .Objects import CONTEXT_ID, SERVICES
LOGGER = logging.getLogger(__name__) LOGGER = logging.getLogger(__name__)
LOGGER.setLevel(logging.DEBUG) LOGGER.setLevel(logging.DEBUG)
......
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