Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
controller
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
TFS
controller
Commits
2f8a2a33
Commit
2f8a2a33
authored
1 year ago
by
Waleed Akbar
Browse files
Options
Downloads
Patches
Plain Diff
improvements in comments
parent
48afe65f
No related branches found
No related tags found
2 merge requests
!294
Release TeraFlowSDN 4.0
,
!207
Resolve "(CTTC) Separation of Monitoring"
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/kpi_manager/tests/test_unitary.py
+1
-45
1 addition, 45 deletions
src/kpi_manager/tests/test_unitary.py
with
1 addition
and
45 deletions
src/kpi_manager/tests/test_unitary.py
+
1
−
45
View file @
2f8a2a33
...
...
@@ -191,50 +191,6 @@ def kpi_manager_client(kpi_manager_service : KpiManagerService): # pylint: disab
LOGGER
.
info
(
'
Closed KpiManagerClient...
'
)
# @pytest.fixture(scope='session')
# def management_db():
# _management_db = ManagementDB('monitoring.db')
# return _management_db
# @pytest.fixture(scope='session')
# def metrics_db(kpi_manager_service : KpiManagerService): # pylint: disable=redefined-outer-name
# return monitoring_service.monitoring_servicer.metrics_db
# # This function os not clear to me (Changes should me made before execution)
# @pytest.fixture(scope='session')
# def metrics_db(monitoring_service : MonitoringService): # pylint: disable=redefined-outer-name
# return monitoring_service.monitoring_servicer.metrics_db
# #_metrics_db = MetricsDBTools.MetricsDB(
# # METRICSDB_HOSTNAME, METRICSDB_ILP_PORT, METRICSDB_REST_PORT, METRICSDB_TABLE_MONITORING_KPIS)
# #return _metrics_db
# @pytest.fixture(scope='session')
# def subs_scheduler():
# _scheduler = BackgroundScheduler(executors={'processpool': ProcessPoolExecutor(max_workers=20)})
# _scheduler.start()
# return _scheduler
# def ingestion_data(kpi_id_int):
# # pylint: disable=redefined-outer-name,unused-argument
# metrics_db = MetricsDB('localhost', '9009', '9000', 'monitoring')
# kpiSampleType = KpiSampleType.KPISAMPLETYPE_PACKETS_RECEIVED
# kpiSampleType_name = KpiSampleType.Name(kpiSampleType).upper().replace('KPISAMPLETYPE_', '')
# for _ in range(50):
# kpiSampleType = kpiSampleType_name
# kpiId = kpi_id_int
# deviceId = 'DEV'+ str(kpi_id_int)
# endpointId = 'END' + str(kpi_id_int)
# serviceId = 'SERV' + str(kpi_id_int)
# sliceId = 'SLC' + str(kpi_id_int)
# connectionId = 'CON' + str(kpi_id_int)
# time_stamp = timestamp_utcnow_to_float()
# kpi_value = 500*random()
# metrics_db.write_KPI(time_stamp, kpiId, kpiSampleType, deviceId, endpointId, serviceId, sliceId, connectionId,
# kpi_value)
# sleep(0.1)
##################################################
# Prepare Environment, should be the first test
##################################################
...
...
@@ -248,7 +204,7 @@ def test_prepare_environment(
context_client
.
SetTopology
(
Topology
(
**
json_topology
(
DEFAULT_TOPOLOGY_NAME
,
context_id
=
context_id
)))
###########################
# Tests Implementation
# Tests Implementation
of Kpi Manager
###########################
# Test case that makes use of client fixture to test server's CreateKpi method
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment