1 # Copyright 2023 highstreet technologies GmbH
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
7 # http://www.apache.org/licenses/LICENSE-2.0
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
15 from network_generation.model.python.o_ran_termination_point import (
18 from network_generation.model.python.type_definitions import (
24 def test_o_ran_termination_point() -> None:
25 o_ran_termination_point: ORanTerminationPoint = ORanTerminationPoint()
26 assert o_ran_termination_point.id == "O-RAN-DU-00-00-00-00-02-OFHS"
27 assert o_ran_termination_point.administrativeState.value == "locked"
28 assert o_ran_termination_point.supporter == "O-RAN-DU-00-00-00-00-02-PHY"
29 assert o_ran_termination_point.parent == 0
30 assert len(str(o_ran_termination_point)) == 337
32 o_ran_termination_point = ORanTerminationPoint(
35 "administrativeState": AdministrativeState.UNLOCKED,
36 "operationalState": OperationalState.ENABLED,
37 "supporter": "my_personal_fan",
38 "parent": ORanTerminationPoint(),
41 assert len(o_ran_termination_point.id) == 5
42 assert o_ran_termination_point.administrativeState.value == "unlocked"
43 assert o_ran_termination_point.operationalState.value == "enabled"
44 assert o_ran_termination_point.supporter == "my_personal_fan"
45 assert type(o_ran_termination_point.parent) is int
46 assert len(str(o_ran_termination_point)) == 316