thousandeyes-sdk-python/alerts_api/test/test_alert_detail.py
2023-12-11 09:29:15 +00:00

79 lines
2.5 KiB
Python

# coding: utf-8
"""
Alerts API
## Overview Manage all alerts, alert rules and alert suppression windows.
The version of the OpenAPI document: 7.0.0
Generated by OpenAPI Generator (https://openapi-generator.tech)
Do not edit the class manually.
""" # noqa: E501
import unittest
import datetime
from alerts_api.models.alert_detail import AlertDetail
class TestAlertDetail(unittest.TestCase):
"""AlertDetail unit test stubs"""
def setUp(self):
pass
def tearDown(self):
pass
def make_instance(self, include_optional) -> AlertDetail:
"""Test AlertDetail
include_option is a boolean, when False only required
params are included, when True both required and
optional params are included """
# uncomment below to create an instance of `AlertDetail`
"""
model = AlertDetail()
if include_optional:
return AlertDetail(
id = 'e9c3bf02-a48c-4aa8-9e5f-898800d6f569',
alert_type = 'http-server',
start_date = '2020-04-23T13:43:16Z',
end_date = '2020-04-23T13:43:16Z',
violation_count = 2,
duration = 60,
links = alerts_api.models.rule_links__links.RuleLinks__links(
rule = alerts_api.models.link.Link(
href = 'https://api.thousandeyes.com/v7/link/to/resource/id',
templated = True,
type = '',
deprecation = '',
name = '',
profile = '',
title = '',
hreflang = '', ), ),
state = 'active',
severity = 'major',
details = [
alerts_api.models.alert_metric_detail.AlertMetricDetail(
end = null,
id = '3379',
name = 'Bucharest, Romania',
start = null,
state = 'active',
type = 'cea_agent', )
]
)
else:
return AlertDetail(
)
"""
def testAlertDetail(self):
"""Test AlertDetail"""
# inst_req_only = self.make_instance(include_optional=False)
# inst_req_and_optional = self.make_instance(include_optional=True)
if __name__ == '__main__':
unittest.main()