Skip to content

Commit a263587

Browse files
author
David Linko
committed
updated test to include new changes
1 parent 31c881c commit a263587

File tree

3 files changed

+32
-39
lines changed

3 files changed

+32
-39
lines changed

anms-core/anms/shared/config.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -126,8 +126,8 @@ class BaseConfig(AbstractConfig):
126126
MQTT_USER = None
127127

128128
# nm Settings
129-
NM_HOST = "amp-manager"
130-
NM_PORT = 8089
129+
NM_HOST = os.environ.get('NM_HOST',"amp-manager")
130+
NM_PORT = os.environ.get('NM_PORT', 8089)
131131
NM_API_BASE ="/nm/api"
132132

133133
# Relation DB Settings (MySQL)
@@ -199,6 +199,9 @@ class BaseConfig(AbstractConfig):
199199
#Transcoding
200200
Transcoder = "Internal"
201201

202+
#alert file
203+
ALERT_FILE = os.environ.get('ALERT_FILE', '/usr/local/share/anms/alerts.json')
204+
202205
def on_finalized(self):
203206
pass
204207

anms-core/anms/shared/manager_checker.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ class ManagerChecker:
3737
def __init__(self, config):
3838
self.known_agents = {}
3939
self.lock = Lock()
40-
self.alert_file = '/usr/local/share/anms/alerts.json'
40+
self.alert_file = config['ALERT_FILE']
4141
self.ui_url = "http://" + config['UI_HOST'] + ":" + str(config['UI_PORT']) + config['UI_API_BASE']
4242
self.manager_connect = True # tracks manager connection status so doesnt repeat alerts of disconnect
4343
self.curr_id = 0 # tracking the alert id for acknowledging

anms-core/integration_test/openapi.json

Lines changed: 26 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@
159159
{
160160
"required": true,
161161
"schema": {
162-
"title": "Agent Id String",
162+
"title": "Agent Endpoint Uri",
163163
"type": "string"
164164
},
165165
"name": "agent_endpoint_uri",
@@ -2517,7 +2517,7 @@
25172517
"required": true,
25182518
"schema": {
25192519
"title": "Agent Id",
2520-
"type": "string"
2520+
"type": "integer"
25212521
},
25222522
"name": "agent_id",
25232523
"in": "path"
@@ -2549,30 +2549,30 @@
25492549
}
25502550
}
25512551
},
2552-
"/report/entries/table/{agent_id}/{correlator_nonce}": {
2552+
"/report/entries/table/{agent_id}/{nonce_cbor}": {
25532553
"get": {
25542554
"tags": [
25552555
"REPORTS"
25562556
],
25572557
"summary": "Report Ac",
2558-
"operationId": "report_ac_report_entries_table__agent_id___correlator_nonce__get",
2558+
"operationId": "report_ac_report_entries_table__agent_id___nonce_cbor__get",
25592559
"parameters": [
25602560
{
25612561
"required": true,
25622562
"schema": {
25632563
"title": "Agent Id",
2564-
"type": "string"
2564+
"type": "integer"
25652565
},
25662566
"name": "agent_id",
25672567
"in": "path"
25682568
},
25692569
{
25702570
"required": true,
25712571
"schema": {
2572-
"title": "Correlator Nonce",
2573-
"type": "integer"
2572+
"title": "Nonce Cbor",
2573+
"type": "string"
25742574
},
2575-
"name": "correlator_nonce",
2575+
"name": "nonce_cbor",
25762576
"in": "path"
25772577
}
25782578
],
@@ -2581,11 +2581,7 @@
25812581
"description": "Successful Response",
25822582
"content": {
25832583
"application/json": {
2584-
"schema": {
2585-
"title": "Response Report Ac Report Entries Table Agent Id Correlator Nonce Get",
2586-
"type": "array",
2587-
"items": {}
2588-
}
2584+
"schema": {}
25892585
}
25902586
}
25912587
},
@@ -4188,7 +4184,7 @@
41884184
"type": "object",
41894185
"properties": {
41904186
"agent_endpoint_uri": {
4191-
"title": "Agent Id String",
4187+
"title": "Agent Endpoint Uri",
41924188
"type": "string"
41934189
},
41944190
"first_registered": {
@@ -4222,24 +4218,21 @@
42224218
"title": "RptEntry",
42234219
"type": "object",
42244220
"properties": {
4225-
"reference_time": {
4226-
"title": "Reference Time",
4227-
"type": "string"
4228-
},
4229-
"agent_id": {
4230-
"title": "Agent Id",
4221+
"ari_rptset_id": {
4222+
"title": "Ari Rptset Id",
42314223
"type": "string"
42324224
},
4233-
"correlator_nonce": {
4234-
"title": "Correlator Nonce",
4235-
"type": "string"
4225+
"reference_time": {
4226+
"title": "Reference Time",
4227+
"type": "string",
4228+
"format": "date-time"
42364229
},
42374230
"report_list": {
42384231
"title": "Report List",
42394232
"type": "string"
42404233
},
4241-
"ari_rptset_id": {
4242-
"title": "Ari Rptset Id",
4234+
"agent_id": {
4235+
"title": "Agent Id",
42434236
"type": "integer"
42444237
}
42454238
}
@@ -4248,24 +4241,21 @@
42484241
"title": "RptEntryBaseInDBBase",
42494242
"type": "object",
42504243
"properties": {
4251-
"reference_time": {
4252-
"title": "Reference Time",
4253-
"type": "string"
4254-
},
4255-
"agent_id": {
4256-
"title": "Agent Id",
4244+
"ari_rptset_id": {
4245+
"title": "Ari Rptset Id",
42574246
"type": "string"
42584247
},
4259-
"correlator_nonce": {
4260-
"title": "Correlator Nonce",
4261-
"type": "string"
4248+
"reference_time": {
4249+
"title": "Reference Time",
4250+
"type": "string",
4251+
"format": "date-time"
42624252
},
42634253
"report_list": {
42644254
"title": "Report List",
42654255
"type": "string"
42664256
},
4267-
"ari_rptset_id": {
4268-
"title": "Ari Rptset Id",
4257+
"agent_id": {
4258+
"title": "Agent Id",
42694259
"type": "integer"
42704260
}
42714261
}

0 commit comments

Comments
 (0)