1 ################################################################################
2 # Copyright (c) 2020 AT&T Intellectual Property. #
4 # Licensed under the Apache License, Version 2.0 (the "License"); #
5 # you may not use this file except in compliance with the License. #
6 # You may obtain a copy of the License at #
8 # http://www.apache.org/licenses/LICENSE-2.0 #
10 # Unless required by applicable law or agreed to in writing, software #
11 # distributed under the License is distributed on an "AS IS" BASIS, #
12 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
13 # See the License for the specific language governing permissions and #
14 # limitations under the License. #
15 ################################################################################
17 controls_schema_file = {
18 "$schema": "http://json-schema.org/draft-07/schema#",
21 "title": "Controls Section Schema",
27 "$id": "#/controls/test",
39 "xapp_name": "test_xapp",
42 "prometheus.io/path": "/ric/v1/metrics",
43 "prometheus.io/port": "8080",
44 "prometheus.io/scrape": "true"
50 "registry": "nexus3.o-ran-sc.org:10002",
51 "name": "o-ran-sc/ric-app-mc",
54 "command": ["/bin/sh"],
55 "args": ["-c", "/playpen/bin/container_start.sh"]
60 "command": ["/usr/local/bin/health_ck"]
62 "initialDelaySeconds": 5,
67 "path": "ric/v1/health/alive",
70 "initialDelaySeconds": 5,
77 "container": "mcxapp",
79 "description": "http service"
83 "container": "mcxapp",
85 "description": "rmr data port for mcxapp"
89 "container": "mcxapp",
91 "description": "rmr route port for mcxapp"
113 "objectName": "UEEventStreamingCounters",
114 "objectInstance": "SgNBAdditionRequest",
115 "name": "SgNBAdditionRequest",
117 "description": "The total number of SG addition request events processed"
120 "objectName": "UEEventStreamingCounters",
121 "objectInstance": "SgNBAdditionRequestAcknowledge",
122 "name": "SgNBAdditionRequestAcknowledge",
124 "description": "The total number of SG addition request acknowledge events processed"
129 mock_json_body_url = {
130 'config-file.json_url': 'http://0.0.0.0:8080/config-file.json',
131 'controls-schema.json_url': 'http://0.0.0.0:8080/schema.json'
134 mock_json_body_url_without_controls = {
135 'config-file.json_url': 'http://0.0.0.0:8080/config-file.json'
139 "config-file.json": config_file,
140 "controls-schema.json": controls_schema_file
143 mock_json_body_without_controls = {
144 "config-file.json": config_file
146 helm_repo_index_response = {'apiVersion': 'v1',
151 'created': '2020-03-12T19:10:17.178396719Z',
152 'description': 'test xApp Helm Chart',
153 'digest': 'd77dfb3f008e5174e90d79bfe982ef85b5dc5930141f6a1bd9995b2fa35',
155 'urls': ['charts/test-1.0.0.tgz'],
159 'generated': '2020-03-16T16:54:44Z',