forked from lthn/blockchain
Introduces a new Python client SDK for the lthn API, generated via OpenAPI Generator. Includes source code, models, API classes, documentation, tests, CI/CD workflows for GitHub and GitLab, and project configuration files.
109 lines
4.5 KiB
Python
Generated
109 lines
4.5 KiB
Python
Generated
# coding: utf-8
|
|
|
|
"""
|
|
Lethean Blockchain API
|
|
|
|
OpenAPI for Lethean Blockchain
|
|
|
|
The version of the OpenAPI document: 6.0.1
|
|
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
|
|
Do not edit the class manually.
|
|
""" # noqa: E501
|
|
|
|
|
|
import unittest
|
|
|
|
from lthn.models.performance_model import PerformanceModel
|
|
|
|
class TestPerformanceModel(unittest.TestCase):
|
|
"""PerformanceModel unit test stubs"""
|
|
|
|
def setUp(self):
|
|
pass
|
|
|
|
def tearDown(self):
|
|
pass
|
|
|
|
def make_instance(self, include_optional) -> PerformanceModel:
|
|
"""Test PerformanceModel
|
|
include_optional 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 `PerformanceModel`
|
|
"""
|
|
model = PerformanceModel()
|
|
if include_optional:
|
|
return PerformanceModel(
|
|
block_processing = lthn.models.block_processing_performance_model.BlockProcessingPerformanceModel(
|
|
block_processing_time_0 = 56,
|
|
block_processing_time_1 = 56,
|
|
target_calculating_time_2 = 56,
|
|
longhash_calculating_time_3 = 56,
|
|
all_txs_insert_time_5 = 56,
|
|
etc_stuff_6 = 56,
|
|
insert_time_4 = 56,
|
|
raise_block_core_event = 56,
|
|
validate_miner_transaction_time = 56,
|
|
collect_rangeproofs_data_from_tx_time = 56,
|
|
verify_multiple_zc_outs_range_proofs_time = 56,
|
|
target_calculating_enum_blocks = 56,
|
|
target_calculating_calc = 56,
|
|
pos_validate_ki_search = 56,
|
|
pos_validate_get_out_keys_for_inputs = 56,
|
|
pos_validate_zvp = 56, ),
|
|
tx_processing = lthn.models.tx_processing_performance_model.TxProcessingPerformanceModel(
|
|
tx_check_inputs = 56,
|
|
tx_add_one_tx = 56,
|
|
tx_process_extra = 56,
|
|
tx_process_attachment = 56,
|
|
tx_process_inputs = 56,
|
|
tx_push_global_index = 56,
|
|
tx_check_exist = 56,
|
|
tx_print_log = 56,
|
|
tx_prapare_append = 56,
|
|
tx_append = 56,
|
|
tx_append_rl_wait = 56,
|
|
tx_append_is_expired = 56,
|
|
tx_store_db = 56,
|
|
tx_check_inputs_prefix_hash = 56,
|
|
tx_check_inputs_attachment_check = 56,
|
|
tx_check_inputs_loop = 56,
|
|
tx_check_inputs_loop_kimage_check = 56,
|
|
tx_check_inputs_loop_ch_in_val_sig = 56,
|
|
tx_check_inputs_loop_scan_outputkeys_get_item_size = 56,
|
|
tx_check_inputs_loop_scan_outputkeys_relative_to_absolute = 56,
|
|
tx_check_inputs_loop_scan_outputkeys_loop = 56,
|
|
tx_check_inputs_loop_scan_outputkeys_loop_get_subitem = 56,
|
|
tx_check_inputs_loop_scan_outputkeys_loop_find_tx = 56,
|
|
tx_check_inputs_loop_scan_outputkeys_loop_handle_output = 56,
|
|
tx_mixin_count = 56, ),
|
|
tx_pool = lthn.models.tx_pool_performance_model.TxPoolPerformanceModel(
|
|
tx_processing_time = 56,
|
|
check_inputs_types_supported_time = 56,
|
|
expiration_validate_time = 56,
|
|
validate_amount_time = 56,
|
|
validate_alias_time = 56,
|
|
check_keyimages_ws_ms_time = 56,
|
|
check_inputs_time = 56,
|
|
begin_tx_time = 56,
|
|
update_db_time = 56,
|
|
db_commit_time = 56,
|
|
check_post_hf4_balance = 56, ),
|
|
db_stat_info = lthn.models.db_stat_info_model.DbStatInfoModel(
|
|
tx_count = 56,
|
|
write_tx_count = 56,
|
|
map_size = 56, )
|
|
)
|
|
else:
|
|
return PerformanceModel(
|
|
)
|
|
"""
|
|
|
|
def testPerformanceModel(self):
|
|
"""Test PerformanceModel"""
|
|
# inst_req_only = self.make_instance(include_optional=False)
|
|
# inst_req_and_optional = self.make_instance(include_optional=True)
|
|
|
|
if __name__ == '__main__':
|
|
unittest.main()
|