mirror of
https://github.com/thousandeyes/thousandeyes-sdk-python.git
synced 2025-12-06 16:05:30 +00:00
103 lines
4.0 KiB
Python
103 lines
4.0 KiB
Python
# coding: utf-8
|
|
|
|
"""
|
|
Endpoint Test Results API
|
|
|
|
Retrieve results for scheduled and dynamic tests on endpoint agents.
|
|
|
|
The version of the OpenAPI document: 7.0.4
|
|
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
|
|
Do not edit the class manually.
|
|
""" # noqa: E501
|
|
|
|
|
|
import unittest
|
|
|
|
from thousandeyes_sdk.endpoint_test_results.models.endpoint_scheduled_test import EndpointScheduledTest
|
|
|
|
class TestEndpointScheduledTest(unittest.TestCase):
|
|
"""EndpointScheduledTest unit test stubs"""
|
|
|
|
def setUp(self):
|
|
pass
|
|
|
|
def tearDown(self):
|
|
pass
|
|
|
|
def make_instance(self, include_optional) -> EndpointScheduledTest:
|
|
"""Test EndpointScheduledTest
|
|
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 `EndpointScheduledTest`
|
|
"""
|
|
model = EndpointScheduledTest()
|
|
if include_optional:
|
|
return EndpointScheduledTest(
|
|
aid = '1234',
|
|
links = thousandeyes_sdk.endpoint_test_results.models.endpoint_test_links.EndpointTestLinks(
|
|
self = null,
|
|
test_results = [{"href":"https://api.thousandeyes.com/v7/endpoint/test-results/scheduled-tests/281474976710706/network/filter"},{"href":"https://api.thousandeyes.com/v7/endpoint/test-results/scheduled-tests/281474976710706/pathvis"}], ),
|
|
agent_selector_config = thousandeyes_sdk.endpoint_test_results.models.endpoint_agent_selector_config.EndpointAgentSelectorConfig(),
|
|
created_date = '2022-07-17T22:00:54Z',
|
|
interval = 120,
|
|
is_enabled = True,
|
|
is_saved_event = False,
|
|
has_path_trace_in_session = True,
|
|
modified_date = '2022-07-17T22:00:54Z',
|
|
network_measurements = True,
|
|
port = 80,
|
|
protocol = 'icmp',
|
|
server = 'www.example.com',
|
|
test_id = '281474976710706',
|
|
test_name = 'Test name',
|
|
type = 'http-server',
|
|
tcp_probe_mode = 'auto',
|
|
alert_rules = [
|
|
thousandeyes_sdk.endpoint_test_results.models.alert_rule.AlertRule(
|
|
rule_id = '127094',
|
|
rule_name = 'The End of the Internet',
|
|
expression = '((hops((hopDelay >= 100 ms))))',
|
|
direction = 'to-target',
|
|
is_default = True,
|
|
alert_type = 'http-server',
|
|
minimum_sources = 10,
|
|
minimum_sources_pct = 99,
|
|
rounds_violating_mode = 'exact',
|
|
rounds_violating_out_of = 5,
|
|
rounds_violating_required = 2,
|
|
severity = 'major', )
|
|
],
|
|
labels = [
|
|
{"labelId":"961","name":"Artem label","isBuiltin":false}
|
|
],
|
|
auth_type = 'none',
|
|
http_time_limit = 5000,
|
|
url = 'www.example.com',
|
|
username = 'username',
|
|
ssl_version_id = '0',
|
|
verify_certificate = False,
|
|
content_regex = '(regex)+',
|
|
follow_redirects = True,
|
|
http_target_time = 100,
|
|
http_version = 1,
|
|
post_body = 'body',
|
|
ssl_version = 'Auto',
|
|
use_ntlm = False,
|
|
user_agent = 'curl'
|
|
)
|
|
else:
|
|
return EndpointScheduledTest(
|
|
type = 'http-server',
|
|
)
|
|
"""
|
|
|
|
def testEndpointScheduledTest(self):
|
|
"""Test EndpointScheduledTest"""
|
|
# inst_req_only = self.make_instance(include_optional=False)
|
|
# inst_req_and_optional = self.make_instance(include_optional=True)
|
|
|
|
if __name__ == '__main__':
|
|
unittest.main()
|