wiliot-certificate 4.4.2__py3-none-any.whl → 4.5.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {brg_certificate → certificate}/ag/wlt_cmd_if.html +10 -4
- {brg_certificate → certificate}/ag/wlt_types_ag.py +1878 -519
- certificate/cert_common.py +1488 -0
- certificate/cert_config.py +480 -0
- {brg_certificate → certificate}/cert_data_sim.py +134 -46
- {brg_certificate → certificate}/cert_defines.py +129 -128
- {brg_certificate → certificate}/cert_gw_sim.py +183 -53
- {brg_certificate → certificate}/cert_mqtt.py +179 -64
- {brg_certificate → certificate}/cert_prints.py +35 -33
- {brg_certificate → certificate}/cert_protobuf.py +15 -6
- {brg_certificate → certificate}/cert_results.py +240 -64
- certificate/cert_utils.py +634 -0
- certificate/certificate.py +205 -0
- certificate/certificate_cli.py +76 -0
- certificate/certificate_eth_test_list.txt +76 -0
- certificate/certificate_sanity_test_list.txt +66 -0
- certificate/certificate_test_list.txt +76 -0
- {brg_certificate → certificate}/tests/calibration/interval_test/interval_test.json +3 -2
- {brg_certificate → certificate}/tests/calibration/interval_test/interval_test.py +7 -6
- certificate/tests/calibration/output_power_test/output_power_test.json +23 -0
- certificate/tests/calibration/output_power_test/output_power_test.py +39 -0
- {brg_certificate → certificate}/tests/calibration/pattern_test/pattern_test.json +2 -1
- {brg_certificate → certificate}/tests/calibration/pattern_test/pattern_test.py +20 -15
- certificate/tests/cloud_connectivity/acl_ext_adv_test/acl_ext_adv_test.json +15 -0
- certificate/tests/cloud_connectivity/acl_ext_adv_test/acl_ext_adv_test.py +140 -0
- certificate/tests/cloud_connectivity/acl_test/acl_test.json +15 -0
- certificate/tests/cloud_connectivity/acl_test/acl_test.py +96 -0
- certificate/tests/cloud_connectivity/brg_ota_test/brg_ota_test.json +19 -0
- certificate/tests/cloud_connectivity/brg_ota_test/brg_ota_test.py +41 -0
- certificate/tests/cloud_connectivity/channel_scan_behaviour_test/channel_scan_behaviour_test.json +19 -0
- certificate/tests/cloud_connectivity/channel_scan_behaviour_test/channel_scan_behaviour_test.py +215 -0
- certificate/tests/cloud_connectivity/connection_test/connection_test.json +18 -0
- certificate/tests/cloud_connectivity/connection_test/connection_test.py +67 -0
- certificate/tests/cloud_connectivity/deduplication_test/deduplication_test.json +15 -0
- certificate/tests/cloud_connectivity/deduplication_test/deduplication_test.py +80 -0
- certificate/tests/cloud_connectivity/downlink_test/downlink_test.json +21 -0
- certificate/tests/cloud_connectivity/downlink_test/downlink_test.py +201 -0
- certificate/tests/cloud_connectivity/ext_adv_stress_test/ext_adv_stress_test.json +17 -0
- certificate/tests/cloud_connectivity/ext_adv_stress_test/ext_adv_stress_test.py +104 -0
- certificate/tests/cloud_connectivity/reboot_test/reboot_test.json +18 -0
- certificate/tests/cloud_connectivity/reboot_test/reboot_test.py +59 -0
- certificate/tests/cloud_connectivity/registration_test/registration_test.json +20 -0
- certificate/tests/cloud_connectivity/registration_test/registration_test.py +384 -0
- certificate/tests/cloud_connectivity/registration_test/registration_test_cli.py +90 -0
- certificate/tests/cloud_connectivity/stress_test/stress_test.json +17 -0
- certificate/tests/cloud_connectivity/stress_test/stress_test.py +101 -0
- certificate/tests/cloud_connectivity/uplink_ext_adv_test/uplink_ext_adv_test.json +25 -0
- certificate/tests/cloud_connectivity/uplink_ext_adv_test/uplink_ext_adv_test.py +92 -0
- certificate/tests/cloud_connectivity/uplink_test/uplink_test.json +20 -0
- certificate/tests/cloud_connectivity/uplink_test/uplink_test.py +169 -0
- {brg_certificate → certificate}/tests/datapath/aging_test/aging_test.json +2 -1
- certificate/tests/datapath/aging_test/aging_test.py +142 -0
- certificate/tests/datapath/event_ble5_test/event_ble5_test.json +17 -0
- certificate/tests/datapath/event_ble5_test/event_ble5_test.py +89 -0
- certificate/tests/datapath/event_test/event_test.json +17 -0
- certificate/tests/datapath/event_test/event_test.py +80 -0
- {brg_certificate → certificate}/tests/datapath/num_of_tags_test/num_of_tags_test.json +4 -3
- {brg_certificate → certificate}/tests/datapath/num_of_tags_test/num_of_tags_test.py +19 -13
- certificate/tests/datapath/output_power_test/output_power_test.json +23 -0
- {brg_certificate → certificate}/tests/datapath/output_power_test/output_power_test.py +17 -6
- {brg_certificate → certificate}/tests/datapath/pacer_interval_ble5_test/pacer_interval_ble5_test.json +2 -1
- {brg_certificate → certificate}/tests/datapath/pacer_interval_ble5_test/pacer_interval_ble5_test.py +13 -11
- {brg_certificate → certificate}/tests/datapath/pacer_interval_test/pacer_interval_test.json +2 -1
- {brg_certificate → certificate}/tests/datapath/pacer_interval_test/pacer_interval_test.py +9 -7
- {brg_certificate → certificate}/tests/datapath/pattern_test/pattern_test.json +3 -2
- {brg_certificate → certificate}/tests/datapath/pattern_test/pattern_test.py +18 -6
- certificate/tests/datapath/pkt_filter_ble5_chl21_test/pkt_filter_ble5_chl21_test.json +20 -0
- certificate/tests/datapath/pkt_filter_ble5_chl21_test/pkt_filter_ble5_chl21_test.py +61 -0
- {brg_certificate → certificate}/tests/datapath/pkt_filter_ble5_test/pkt_filter_ble5_test.json +2 -1
- {brg_certificate → certificate}/tests/datapath/pkt_filter_ble5_test/pkt_filter_ble5_test.py +15 -14
- certificate/tests/datapath/pkt_filter_brg2gw_ext_adv_test/pkt_filter_brg2gw_ext_adv_test.json +19 -0
- certificate/tests/datapath/pkt_filter_brg2gw_ext_adv_test/pkt_filter_brg2gw_ext_adv_test.py +85 -0
- {brg_certificate → certificate}/tests/datapath/pkt_filter_gen3_test/pkt_filter_gen3_test.json +2 -1
- {brg_certificate → certificate}/tests/datapath/pkt_filter_gen3_test/pkt_filter_gen3_test.py +10 -9
- {brg_certificate → certificate}/tests/datapath/pkt_filter_test/pkt_filter_test.json +2 -1
- {brg_certificate → certificate}/tests/datapath/pkt_filter_test/pkt_filter_test.py +10 -9
- {brg_certificate → certificate}/tests/datapath/rssi_threshold_test/rssi_threshold_test.json +3 -2
- {brg_certificate → certificate}/tests/datapath/rssi_threshold_test/rssi_threshold_test.py +9 -8
- brg_certificate/tests/datapath/output_power_test/output_power_test.json → certificate/tests/datapath/rx_channel_hopping_test/rx_channel_hopping_test.json +6 -4
- certificate/tests/datapath/rx_channel_hopping_test/rx_channel_hopping_test.py +77 -0
- {brg_certificate → certificate}/tests/datapath/rx_channel_test/rx_channel_test.json +3 -2
- {brg_certificate → certificate}/tests/datapath/rx_channel_test/rx_channel_test.py +7 -6
- {brg_certificate → certificate}/tests/datapath/rx_rate_gen2_test/rx_rate_gen2_test.json +8 -7
- {brg_certificate → certificate}/tests/datapath/rx_rate_gen2_test/rx_rate_gen2_test.py +113 -73
- {brg_certificate → certificate}/tests/datapath/rx_rate_gen3_test/rx_rate_gen3_test.json +8 -7
- {brg_certificate → certificate}/tests/datapath/rx_rate_gen3_test/rx_rate_gen3_test.py +112 -72
- {brg_certificate → certificate}/tests/datapath/stress_gen3_test/stress_gen3_test.json +4 -3
- {brg_certificate → certificate}/tests/datapath/stress_gen3_test/stress_gen3_test.py +15 -11
- {brg_certificate → certificate}/tests/datapath/stress_test/stress_test.json +4 -3
- {brg_certificate → certificate}/tests/datapath/stress_test/stress_test.py +15 -11
- {brg_certificate → certificate}/tests/datapath/tx_repetition_test/tx_repetition_test.json +3 -1
- {brg_certificate → certificate}/tests/datapath/tx_repetition_test/tx_repetition_test.py +14 -13
- certificate/tests/edge_mgmt/action_blink_test/action_blink_test.json +15 -0
- certificate/tests/edge_mgmt/action_blink_test/action_blink_test.py +24 -0
- certificate/tests/edge_mgmt/action_get_battery_sensor_test/action_get_battery_sensor_test.json +15 -0
- certificate/tests/edge_mgmt/action_get_battery_sensor_test/action_get_battery_sensor_test.py +43 -0
- certificate/tests/edge_mgmt/action_get_module_test/action_get_module_test.json +15 -0
- certificate/tests/edge_mgmt/action_get_module_test/action_get_module_test.py +42 -0
- certificate/tests/edge_mgmt/action_get_pof_data_test/action_get_pof_data_test.json +15 -0
- certificate/tests/edge_mgmt/action_get_pof_data_test/action_get_pof_data_test.py +44 -0
- certificate/tests/edge_mgmt/action_gw_hb_test/action_gw_hb_test.json +16 -0
- certificate/tests/edge_mgmt/action_gw_hb_test/action_gw_hb_test.py +42 -0
- certificate/tests/edge_mgmt/action_reboot_test/action_reboot_test.json +15 -0
- certificate/tests/edge_mgmt/action_reboot_test/action_reboot_test.py +49 -0
- certificate/tests/edge_mgmt/action_restore_defaults_test/action_restore_defaults_test.json +15 -0
- certificate/tests/edge_mgmt/action_restore_defaults_test/action_restore_defaults_test.py +102 -0
- certificate/tests/edge_mgmt/action_send_hb_test/action_send_hb_test.json +15 -0
- certificate/tests/edge_mgmt/action_send_hb_test/action_send_hb_test.py +45 -0
- {brg_certificate → certificate}/tests/edge_mgmt/periodic_msgs_test/periodic_msgs_test.json +3 -2
- {brg_certificate → certificate}/tests/edge_mgmt/periodic_msgs_test/periodic_msgs_test.py +22 -11
- {brg_certificate → certificate}/tests/energy2400/duty_cycle_test/duty_cycle_test.json +2 -1
- {brg_certificate → certificate}/tests/energy2400/duty_cycle_test/duty_cycle_test.py +7 -6
- certificate/tests/energy2400/output_power_test/output_power_test.json +23 -0
- {brg_certificate → certificate}/tests/energy2400/output_power_test/output_power_test.py +17 -6
- {brg_certificate → certificate}/tests/energy2400/pattern_test/pattern_test.json +2 -1
- {brg_certificate → certificate}/tests/energy2400/pattern_test/pattern_test.py +7 -6
- certificate/tests/energy2400/signal_indicator_ble5_test/signal_indicator_ble5_test.json +26 -0
- certificate/tests/energy2400/signal_indicator_ble5_test/signal_indicator_ble5_test.py +379 -0
- certificate/tests/energy2400/signal_indicator_ext_adv_test/signal_indicator_ext_adv_test.json +20 -0
- certificate/tests/energy2400/signal_indicator_ext_adv_test/signal_indicator_ext_adv_test.py +173 -0
- certificate/tests/energy2400/signal_indicator_test/signal_indicator_test.json +24 -0
- certificate/tests/energy2400/signal_indicator_test/signal_indicator_test.py +350 -0
- {brg_certificate → certificate}/tests/energy_sub1g/duty_cycle_test/duty_cycle_test.json +2 -1
- {brg_certificate → certificate}/tests/energy_sub1g/duty_cycle_test/duty_cycle_test.py +7 -6
- {brg_certificate → certificate}/tests/energy_sub1g/pattern_test/pattern_test.json +2 -1
- {brg_certificate → certificate}/tests/energy_sub1g/pattern_test/pattern_test.py +7 -6
- {brg_certificate → certificate}/tests/pwr_mgmt/pwr_mgmt_test/pwr_mgmt_test.json +2 -1
- {brg_certificate → certificate}/tests/pwr_mgmt/pwr_mgmt_test/pwr_mgmt_test.py +10 -10
- {brg_certificate → certificate}/tests/sensors/ext_sensor_test/ext_sensor_test.json +5 -4
- certificate/tests/sensors/ext_sensor_test/ext_sensor_test.py +450 -0
- certificate/wlt_types.py +122 -0
- {gw_certificate → common}/api_if/202/status.json +6 -0
- {gw_certificate → common}/api_if/203/status.json +6 -0
- {gw_certificate → common}/api_if/204/status.json +6 -0
- common/api_if/206/data.json +85 -0
- common/api_if/206/status.json +69 -0
- common/api_if/api_validation.py +91 -0
- common/web/templates/generator.html +210 -0
- common/web/templates/index.html +20 -0
- common/web/templates/menu.html +54 -0
- common/web/templates/parser.html +53 -0
- {brg_certificate/ag → common/web/templates}/wlt_types.html +1216 -191
- common/web/web_utils.py +399 -0
- {brg_certificate → common}/wltPb_pb2.py +14 -12
- {gw_certificate/common → common}/wltPb_pb2.pyi +16 -2
- gui_certificate/gui_certificate_cli.py +14 -0
- gui_certificate/server.py +1267 -0
- gui_certificate/templates/cert_run.html +1273 -0
- wiliot_certificate-4.5.0.dist-info/METADATA +99 -0
- wiliot_certificate-4.5.0.dist-info/RECORD +168 -0
- {wiliot_certificate-4.4.2.dist-info → wiliot_certificate-4.5.0.dist-info}/WHEEL +1 -1
- wiliot_certificate-4.5.0.dist-info/entry_points.txt +5 -0
- wiliot_certificate-4.5.0.dist-info/top_level.txt +3 -0
- brg_certificate/ag/energous_v0_defines.py +0 -925
- brg_certificate/ag/energous_v1_defines.py +0 -931
- brg_certificate/ag/energous_v2_defines.py +0 -925
- brg_certificate/ag/energous_v3_defines.py +0 -925
- brg_certificate/ag/energous_v4_defines.py +0 -925
- brg_certificate/ag/fanstel_lan_v0_defines.py +0 -925
- brg_certificate/ag/fanstel_lte_v0_defines.py +0 -925
- brg_certificate/ag/fanstel_wifi_v0_defines.py +0 -925
- brg_certificate/ag/minew_lte_v0_defines.py +0 -925
- brg_certificate/ag/wlt_types_ag_jsons/brg2brg_ota.json +0 -142
- brg_certificate/ag/wlt_types_ag_jsons/brg2gw_hb.json +0 -785
- brg_certificate/ag/wlt_types_ag_jsons/brg2gw_hb_sleep.json +0 -139
- brg_certificate/ag/wlt_types_ag_jsons/calibration.json +0 -394
- brg_certificate/ag/wlt_types_ag_jsons/custom.json +0 -515
- brg_certificate/ag/wlt_types_ag_jsons/datapath.json +0 -672
- brg_certificate/ag/wlt_types_ag_jsons/energy2400.json +0 -550
- brg_certificate/ag/wlt_types_ag_jsons/energySub1g.json +0 -595
- brg_certificate/ag/wlt_types_ag_jsons/externalSensor.json +0 -598
- brg_certificate/ag/wlt_types_ag_jsons/interface.json +0 -938
- brg_certificate/ag/wlt_types_ag_jsons/powerManagement.json +0 -1234
- brg_certificate/ag/wlt_types_ag_jsons/side_info_sensor.json +0 -105
- brg_certificate/ag/wlt_types_ag_jsons/signal_indicator_data.json +0 -77
- brg_certificate/ag/wlt_types_ag_jsons/unified_echo_ext_pkt.json +0 -61
- brg_certificate/ag/wlt_types_ag_jsons/unified_echo_pkt.json +0 -110
- brg_certificate/brg_certificate.py +0 -225
- brg_certificate/brg_certificate_cli.py +0 -63
- brg_certificate/cert_common.py +0 -923
- brg_certificate/cert_config.py +0 -402
- brg_certificate/cert_utils.py +0 -362
- brg_certificate/certificate_bcc_sanity_test_list.txt +0 -40
- brg_certificate/certificate_bcc_test_list.txt +0 -48
- brg_certificate/certificate_sanity_test_list.txt +0 -43
- brg_certificate/certificate_test_list.txt +0 -53
- brg_certificate/config/eclipse.json +0 -10
- brg_certificate/config/hivemq.json +0 -10
- brg_certificate/config/mosquitto.json +0 -10
- brg_certificate/config/mosquitto.md +0 -95
- brg_certificate/config/wiliot-dev.json +0 -10
- brg_certificate/restore_brg.py +0 -61
- brg_certificate/tests/calibration/output_power_test/output_power_test.json +0 -16
- brg_certificate/tests/calibration/output_power_test/output_power_test.py +0 -28
- brg_certificate/tests/datapath/aging_test/aging_test.py +0 -143
- brg_certificate/tests/datapath/pacer_interval_tags_count_test/pacer_interval_tags_count_test.json +0 -16
- brg_certificate/tests/datapath/pacer_interval_tags_count_test/pacer_interval_tags_count_test.py +0 -73
- brg_certificate/tests/datapath/tx_repetition_algo_test/tx_repetition_algo_test.json +0 -17
- brg_certificate/tests/datapath/tx_repetition_algo_test/tx_repetition_algo_test.py +0 -118
- brg_certificate/tests/edge_mgmt/actions_test/actions_test.json +0 -14
- brg_certificate/tests/edge_mgmt/actions_test/actions_test.py +0 -396
- brg_certificate/tests/edge_mgmt/brg2brg_ota_ble5_test/brg2brg_ota_ble5_test.json +0 -20
- brg_certificate/tests/edge_mgmt/brg2brg_ota_ble5_test/brg2brg_ota_ble5_test.py +0 -94
- brg_certificate/tests/edge_mgmt/brg2brg_ota_test/brg2brg_ota_test.json +0 -19
- brg_certificate/tests/edge_mgmt/brg2brg_ota_test/brg2brg_ota_test.py +0 -87
- brg_certificate/tests/edge_mgmt/leds_test/leds_test.json +0 -17
- brg_certificate/tests/edge_mgmt/leds_test/leds_test.py +0 -223
- brg_certificate/tests/edge_mgmt/ota_test/ota_test.json +0 -17
- brg_certificate/tests/edge_mgmt/ota_test/ota_test.py +0 -128
- brg_certificate/tests/energy2400/output_power_test/output_power_test.json +0 -16
- brg_certificate/tests/energy2400/signal_indicator_ble5_10_250k_test/signal_indicator_ble5_10_250k_test.json +0 -20
- brg_certificate/tests/energy2400/signal_indicator_ble5_10_250k_test/signal_indicator_ble5_10_250k_test.py +0 -321
- brg_certificate/tests/energy2400/signal_indicator_ble5_10_500k_test/signal_indicator_ble5_10_500k_test.json +0 -20
- brg_certificate/tests/energy2400/signal_indicator_ble5_10_500k_test/signal_indicator_ble5_10_500k_test.py +0 -321
- brg_certificate/tests/energy2400/signal_indicator_sub1g_2_4_test/signal_indicator_sub1g_2_4_test.json +0 -20
- brg_certificate/tests/energy2400/signal_indicator_sub1g_2_4_test/signal_indicator_sub1g_2_4_test.py +0 -141
- brg_certificate/tests/energy2400/signal_indicator_test/signal_indicator_test.json +0 -20
- brg_certificate/tests/energy2400/signal_indicator_test/signal_indicator_test.py +0 -276
- brg_certificate/tests/energy_sub1g/signal_indicator_functionality_test/signal_indicator_functionality_test.json +0 -20
- brg_certificate/tests/energy_sub1g/signal_indicator_functionality_test/signal_indicator_functionality_test.py +0 -390
- brg_certificate/tests/energy_sub1g/signal_indicator_test/signal_indicator_test.json +0 -16
- brg_certificate/tests/energy_sub1g/signal_indicator_test/signal_indicator_test.py +0 -28
- brg_certificate/tests/sensors/ext_sensor_test/ext_sensor_test.py +0 -305
- brg_certificate/wltPb_pb2.pyi +0 -234
- brg_certificate/wlt_types.py +0 -113
- gw_certificate/ag/ut_defines.py +0 -364
- gw_certificate/ag/wlt_types.py +0 -85
- gw_certificate/ag/wlt_types_ag.py +0 -5310
- gw_certificate/ag/wlt_types_data.py +0 -64
- gw_certificate/api/extended_api.py +0 -23
- gw_certificate/api_if/200/data.json +0 -106
- gw_certificate/api_if/200/status.json +0 -47
- gw_certificate/api_if/201/data.json +0 -98
- gw_certificate/api_if/201/status.json +0 -53
- gw_certificate/api_if/205/logs.json +0 -12
- gw_certificate/api_if/api_validation.py +0 -38
- gw_certificate/api_if/gw_capabilities.py +0 -54
- gw_certificate/cert_results.py +0 -145
- gw_certificate/common/analysis_data_bricks.py +0 -60
- gw_certificate/common/debug.py +0 -42
- gw_certificate/common/serialization_formatter.py +0 -93
- gw_certificate/common/utils.py +0 -8
- gw_certificate/common/utils_defines.py +0 -15
- gw_certificate/common/wltPb_pb2.py +0 -84
- gw_certificate/gw_certificate.py +0 -154
- gw_certificate/gw_certificate_cli.py +0 -87
- gw_certificate/interface/4.4.91_app.zip +0 -0
- gw_certificate/interface/4.4.91_sd_bl_app.zip +0 -0
- gw_certificate/interface/ble_simulator.py +0 -61
- gw_certificate/interface/ble_sniffer.py +0 -189
- gw_certificate/interface/flash_fw.py +0 -90
- gw_certificate/interface/if_defines.py +0 -36
- gw_certificate/interface/mqtt.py +0 -563
- gw_certificate/interface/nrfutil-linux +0 -0
- gw_certificate/interface/nrfutil-mac +0 -0
- gw_certificate/interface/nrfutil.exe +0 -0
- gw_certificate/interface/pkt_generator.py +0 -594
- gw_certificate/interface/uart_if.py +0 -236
- gw_certificate/interface/uart_ports.py +0 -20
- gw_certificate/templates/results.html +0 -241
- gw_certificate/templates/stage.html +0 -22
- gw_certificate/templates/table.html +0 -6
- gw_certificate/templates/test.html +0 -38
- gw_certificate/tests/__init__.py +0 -10
- gw_certificate/tests/actions.py +0 -289
- gw_certificate/tests/bad_crc_to_PER_quantization.csv +0 -51
- gw_certificate/tests/connection.py +0 -188
- gw_certificate/tests/downlink.py +0 -172
- gw_certificate/tests/generic.py +0 -238
- gw_certificate/tests/registration.py +0 -340
- gw_certificate/tests/static/__init__.py +0 -0
- gw_certificate/tests/static/connection_defines.py +0 -9
- gw_certificate/tests/static/downlink_defines.py +0 -9
- gw_certificate/tests/static/generated_packet_table.py +0 -195
- gw_certificate/tests/static/packet_table.csv +0 -10067
- gw_certificate/tests/static/references.py +0 -5
- gw_certificate/tests/static/uplink_defines.py +0 -14
- gw_certificate/tests/throughput.py +0 -240
- gw_certificate/tests/uplink.py +0 -853
- wiliot_certificate-4.4.2.dist-info/METADATA +0 -211
- wiliot_certificate-4.4.2.dist-info/RECORD +0 -210
- wiliot_certificate-4.4.2.dist-info/entry_points.txt +0 -3
- wiliot_certificate-4.4.2.dist-info/top_level.txt +0 -3
- {brg_certificate → certificate}/__init__.py +0 -0
- {gw_certificate → common}/api_if/202/data.json +0 -0
- {gw_certificate/api_if/200 → common/api_if/202}/logs.json +0 -0
- {gw_certificate → common}/api_if/203/data.json +0 -0
- {gw_certificate/api_if/201 → common/api_if/203}/logs.json +0 -0
- {gw_certificate → common}/api_if/204/data.json +0 -0
- {gw_certificate/api_if/202 → common/api_if/204}/logs.json +0 -0
- {gw_certificate → common}/api_if/205/data.json +0 -0
- {gw_certificate/api_if/203 → common/api_if/205}/logs.json +0 -0
- {gw_certificate → common}/api_if/205/status.json +0 -0
- {gw_certificate/api_if/204 → common/api_if/206}/logs.json +0 -0
- {gw_certificate → common/api_if}/__init__.py +0 -0
- {gw_certificate/api_if → gui_certificate}/__init__.py +0 -0
- {wiliot_certificate-4.4.2.dist-info → wiliot_certificate-4.5.0.dist-info}/licenses/LICENSE +0 -0
gw_certificate/tests/downlink.py
DELETED
|
@@ -1,172 +0,0 @@
|
|
|
1
|
-
import base64
|
|
2
|
-
import datetime
|
|
3
|
-
import json
|
|
4
|
-
import os
|
|
5
|
-
import time
|
|
6
|
-
import pandas as pd
|
|
7
|
-
import plotly.express as px
|
|
8
|
-
from google.protobuf.json_format import MessageToDict
|
|
9
|
-
|
|
10
|
-
from gw_certificate.common import wltPb_pb2
|
|
11
|
-
from gw_certificate.common.debug import debug_print
|
|
12
|
-
from gw_certificate.interface.ble_sniffer import BLESniffer, BLESnifferContext
|
|
13
|
-
from gw_certificate.interface.if_defines import RX_CHANNELS
|
|
14
|
-
from gw_certificate.tests.static.downlink_defines import *
|
|
15
|
-
from gw_certificate.interface.mqtt import MqttClient
|
|
16
|
-
from gw_certificate.interface.pkt_generator import BrgPktGenerator
|
|
17
|
-
from gw_certificate.tests.generic import PassCriteria, PERFECT_SCORE, MINIMUM_SCORE, INCONCLUSIVE_MINIMUM, GenericTest, GenericStage
|
|
18
|
-
|
|
19
|
-
class GenericDownlinkStage(GenericStage):
|
|
20
|
-
def __init__(self, sniffer:BLESniffer, mqttc:MqttClient, pkt_gen:BrgPktGenerator, stage_name, **kwargs):
|
|
21
|
-
self.__dict__.update(kwargs)
|
|
22
|
-
super().__init__(stage_name=stage_name, **self.__dict__)
|
|
23
|
-
|
|
24
|
-
#Clients
|
|
25
|
-
self.sniffer = sniffer
|
|
26
|
-
self.mqttc = mqttc
|
|
27
|
-
self.pkt_gen = pkt_gen
|
|
28
|
-
|
|
29
|
-
#Stage Params
|
|
30
|
-
self.sent_pkts = []
|
|
31
|
-
self.sniffed_pkts = pd.DataFrame()
|
|
32
|
-
|
|
33
|
-
#Paths
|
|
34
|
-
self.sent_csv_path = os.path.join(self.test_dir, f'{self.stage_name}_sent.csv')
|
|
35
|
-
self.sniffed_csv_path = os.path.join(self.test_dir, f'{self.stage_name}_sniffed.csv')
|
|
36
|
-
self.graph_html_path = os.path.join(self.test_dir, f'{self.stage_name}.html')
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
def prepare_stage(self):
|
|
40
|
-
super().prepare_stage()
|
|
41
|
-
self.sniffer.flush_pkts()
|
|
42
|
-
|
|
43
|
-
def send_adv_payloads(self, tx_max_durations=TX_MAX_DURATIONS, retries=RETRIES):
|
|
44
|
-
sent_pkts = []
|
|
45
|
-
for tx_max_duration in tx_max_durations:
|
|
46
|
-
debug_print(f'Tx Max Duration {tx_max_duration}')
|
|
47
|
-
for retry in retries:
|
|
48
|
-
self.pkt_gen.increment_all()
|
|
49
|
-
brg_hb = self.pkt_gen.get_brg_hb()
|
|
50
|
-
tx_max_retries = tx_max_duration//100
|
|
51
|
-
sent_payload = self.mqttc.advertise_packet(raw_packet=brg_hb, tx_max_duration=tx_max_duration, use_retries=self.use_retries)
|
|
52
|
-
if isinstance(sent_payload, wltPb_pb2.DownlinkMessage):
|
|
53
|
-
sent_payload = MessageToDict(sent_payload)
|
|
54
|
-
# Decode b64-encoded bytes
|
|
55
|
-
sent_payload['txPacket']['payload'] = base64.b64decode(sent_payload['txPacket']['payload']).hex().upper()
|
|
56
|
-
else:
|
|
57
|
-
sent_payload = json.dumps(sent_payload)
|
|
58
|
-
debug_print(f'{sent_payload} sent to GW')
|
|
59
|
-
sent_pkts.append({'tx_max_duration': tx_max_duration, 'tx_max_retries': tx_max_retries,
|
|
60
|
-
'retry': retry, 'pkt': brg_hb[12:], 'payload': sent_payload, 'time_sent': datetime.datetime.now()})
|
|
61
|
-
time.sleep(max(MAX_RX_TX_PERIOD_SECS, (tx_max_duration/1000)*1.2))
|
|
62
|
-
time.sleep(10)
|
|
63
|
-
return sent_pkts
|
|
64
|
-
|
|
65
|
-
def process_sniffed_pkts(self, sent_pkts, sniffer:BLESniffer):
|
|
66
|
-
for pkt in sent_pkts:
|
|
67
|
-
# Get vars from dict
|
|
68
|
-
raw_packet = pkt['pkt']
|
|
69
|
-
# Get packets from sniffer
|
|
70
|
-
sniffed_pkts = sniffer.get_filtered_packets(raw_packet=raw_packet)
|
|
71
|
-
pkt['channel'] = str(sniffer.rx_channel)
|
|
72
|
-
pkt['num_pkts_received'] = len(sniffed_pkts)
|
|
73
|
-
self.sniffed_pkts = pd.concat([self.sniffed_pkts, sniffed_pkts.to_pandas()])
|
|
74
|
-
self.sent_pkts += sent_pkts
|
|
75
|
-
|
|
76
|
-
def generate_stage_report(self):
|
|
77
|
-
# Create graph and trendline
|
|
78
|
-
self.add_report_header()
|
|
79
|
-
self.sent_pkts = pd.DataFrame(self.sent_pkts)
|
|
80
|
-
x_value = ('tx_max_duration', 'TX Max Duration') if not self.use_retries else ('tx_max_retries', 'TX Max Retries')
|
|
81
|
-
fig = px.scatter(self.sent_pkts, x=x_value[0], y='num_pkts_received', color='channel', title=f'Packets Received by Sniffer / {x_value[1]}',
|
|
82
|
-
trendline='ols', labels={x_value[0]: x_value[1], 'num_pkts_received': 'Number of packets received', 'channel': "BLE Adv. Channel"})
|
|
83
|
-
fig.update_layout(scattermode="group", scattergap=0.95)
|
|
84
|
-
trendline_info = px.get_trendline_results(fig)
|
|
85
|
-
# Calculate whether stage pass/failed
|
|
86
|
-
self.stage_pass = PERFECT_SCORE
|
|
87
|
-
for channel, channel_df in trendline_info.groupby('BLE Adv. Channel'):
|
|
88
|
-
channel_pass = PERFECT_SCORE
|
|
89
|
-
channel_err_summary = ''
|
|
90
|
-
channel_pkts = self.sent_pkts[self.sent_pkts['channel'] == channel]
|
|
91
|
-
channel_trendline = channel_df['px_fit_results'].iloc[0]
|
|
92
|
-
slope = channel_trendline.params[1]
|
|
93
|
-
rsquared = channel_trendline.rsquared
|
|
94
|
-
# Determine Channel Pass
|
|
95
|
-
channel_pass, channel_err_summary = PassCriteria.calc_for_stage_downlink(rsquared, slope, self.stage_name, sum(channel_pkts['num_pkts_received']))
|
|
96
|
-
if channel_pass < self.stage_pass:
|
|
97
|
-
self.stage_pass = channel_pass
|
|
98
|
-
self.error_summary = channel_err_summary
|
|
99
|
-
self.add_to_stage_report(f"Channel {channel}: {PassCriteria.to_string(channel_pass)}")
|
|
100
|
-
self.add_to_stage_report(f"- Total {len(channel_pkts['payload'])} MQTT payloads sent")
|
|
101
|
-
self.add_to_stage_report(f"- Total {sum(channel_pkts['num_pkts_received'])} BLE Packets received by sniffer (including duplicates)")
|
|
102
|
-
self.add_to_stage_report(f"- R Value: {rsquared} | Slope: {slope}")
|
|
103
|
-
# Export all stage data
|
|
104
|
-
self.sent_pkts.to_csv(self.sent_csv_path)
|
|
105
|
-
self.add_to_stage_report(f'\nSent data saved - {self.sent_csv_path}')
|
|
106
|
-
self.sniffed_pkts.to_csv(self.sniffed_csv_path)
|
|
107
|
-
self.add_to_stage_report(f'Sniffed data saved - {self.sniffed_csv_path}')
|
|
108
|
-
fig.write_html(self.graph_html_path)
|
|
109
|
-
self.add_to_stage_report(f'Graph saved - {self.graph_html_path}')
|
|
110
|
-
debug_print(self.report)
|
|
111
|
-
|
|
112
|
-
# Generate HTML
|
|
113
|
-
graph_div = fig.to_html(full_html=False, include_plotlyjs='cdn')
|
|
114
|
-
self.report_html = self.template_engine.render_template('stage.html', stage=self,
|
|
115
|
-
stage_report=self.report.split('\n'), graph = graph_div)
|
|
116
|
-
return self.report
|
|
117
|
-
|
|
118
|
-
class SanityStage(GenericDownlinkStage):
|
|
119
|
-
def __init__(self, **kwargs):
|
|
120
|
-
self.__dict__.update(kwargs)
|
|
121
|
-
self.stage_tooltip = ("Verifies that the gateway advertises requested packets. "
|
|
122
|
-
"These are requested via Advertisement actions published to the 'update' topic (MQTT)")
|
|
123
|
-
super().__init__(**self.__dict__, stage_name=type(self).__name__)
|
|
124
|
-
|
|
125
|
-
def run(self):
|
|
126
|
-
super().run()
|
|
127
|
-
for channel in RX_CHANNELS:
|
|
128
|
-
debug_print(f'RX Channel {channel}')
|
|
129
|
-
with BLESnifferContext(self.sniffer, channel) as sniffer:
|
|
130
|
-
# Send the packets
|
|
131
|
-
sent_pkts = self.send_adv_payloads(STAGE_CONFIGS[SANITY_STAGE][0], STAGE_CONFIGS[SANITY_STAGE][1])
|
|
132
|
-
# Process sniffed packets
|
|
133
|
-
self.process_sniffed_pkts(sent_pkts, sniffer)
|
|
134
|
-
return True
|
|
135
|
-
|
|
136
|
-
class CorrelationStage(GenericDownlinkStage):
|
|
137
|
-
def __init__(self, **kwargs):
|
|
138
|
-
self.__dict__.update(kwargs)
|
|
139
|
-
self.stage_tooltip = ("Checks how consistently the gateway advertises packets. "
|
|
140
|
-
"Expects a consistently increasing packets count with increasing 'txMaxDuration'")
|
|
141
|
-
super().__init__(**self.__dict__, stage_name=type(self).__name__)
|
|
142
|
-
|
|
143
|
-
def run(self):
|
|
144
|
-
super().run()
|
|
145
|
-
for channel in RX_CHANNELS:
|
|
146
|
-
debug_print(f'RX Channel {channel}')
|
|
147
|
-
with BLESnifferContext(self.sniffer, channel) as sniffer:
|
|
148
|
-
# Send the packets
|
|
149
|
-
sent_pkts = self.send_adv_payloads(STAGE_CONFIGS[CORRELATION_STAGE][0], STAGE_CONFIGS[CORRELATION_STAGE][1])
|
|
150
|
-
# Process sniffed packets
|
|
151
|
-
self.process_sniffed_pkts(sent_pkts, sniffer)
|
|
152
|
-
return True
|
|
153
|
-
|
|
154
|
-
STAGES = [SanityStage, CorrelationStage]
|
|
155
|
-
|
|
156
|
-
class DownlinkTest(GenericTest):
|
|
157
|
-
def __init__(self, **kwargs):
|
|
158
|
-
self.test_tooltip = "Stages examining gateway advertisements by issuing advertisement actions (txPacket)"
|
|
159
|
-
self.__dict__.update(kwargs)
|
|
160
|
-
super().__init__(**self.__dict__, test_name=type(self).__name__)
|
|
161
|
-
self.pkt_gen = BrgPktGenerator()
|
|
162
|
-
self.pkt_gen.set_bridge_id(DEFAULT_BRG_ID)
|
|
163
|
-
self.use_retries = self.topic_suffix == '-test'
|
|
164
|
-
self.stages = [stage(**self.__dict__) for stage in STAGES]
|
|
165
|
-
|
|
166
|
-
def run(self):
|
|
167
|
-
super().run()
|
|
168
|
-
for stage in self.stages:
|
|
169
|
-
stage.prepare_stage()
|
|
170
|
-
stage.run()
|
|
171
|
-
self.add_to_test_report(stage.generate_stage_report())
|
|
172
|
-
self.test_pass = PassCriteria.calc_for_test(self, stage)
|
gw_certificate/tests/generic.py
DELETED
|
@@ -1,238 +0,0 @@
|
|
|
1
|
-
import datetime
|
|
2
|
-
import os
|
|
3
|
-
from typing import Literal
|
|
4
|
-
import math
|
|
5
|
-
|
|
6
|
-
from gw_certificate.common.debug import debug_print
|
|
7
|
-
from gw_certificate.api_if.gw_capabilities import GWCapabilities
|
|
8
|
-
from gw_certificate.interface.ble_simulator import BLESimulator
|
|
9
|
-
from gw_certificate.interface.mqtt import MqttClient
|
|
10
|
-
from gw_certificate.ag.ut_defines import TEST_PASSED, TEST_FAILED, TEST_INCONCLUSIVE, TEST_OPTIONAL, TEST_WARNING, TEST_INFO
|
|
11
|
-
|
|
12
|
-
PASS_STATUS = {True: 'PASS', False: 'FAIL'}
|
|
13
|
-
|
|
14
|
-
# Score values for pass/inconclusive/fail
|
|
15
|
-
PERFECT_SCORE = 100
|
|
16
|
-
PASS_MINIMUM = 80
|
|
17
|
-
INCONCLUSIVE_MINIMUM = 70
|
|
18
|
-
INIT_INCONCLUSIVE_MINIMUM = 40
|
|
19
|
-
MINIMUM_SCORE = 0
|
|
20
|
-
|
|
21
|
-
# Results indications for stages. Must always be synced with frontend.
|
|
22
|
-
# 'score' shows as pass/inconclusive/fail. 'info' shows as info/warning.
|
|
23
|
-
SCORE_BASED = 'score'
|
|
24
|
-
INFORMATIVE = 'info'
|
|
25
|
-
OPTIONAL = 'optional'
|
|
26
|
-
|
|
27
|
-
ERR_SUMMARY_DEFAULT = 'View the stage report for more info. '
|
|
28
|
-
|
|
29
|
-
class PassCriteria():
|
|
30
|
-
def __init__(self):
|
|
31
|
-
pass
|
|
32
|
-
|
|
33
|
-
@staticmethod
|
|
34
|
-
def to_string(pass_value:int) -> str:
|
|
35
|
-
if pass_value >= PASS_MINIMUM:
|
|
36
|
-
return 'Pass'
|
|
37
|
-
elif pass_value >= INCONCLUSIVE_MINIMUM:
|
|
38
|
-
return 'Inconclusive'
|
|
39
|
-
else:
|
|
40
|
-
return 'Fail'
|
|
41
|
-
|
|
42
|
-
@staticmethod
|
|
43
|
-
def calc_for_stage_downlink(rsquared, slope, stage_name:str, pkts_received):
|
|
44
|
-
error_msg = ''
|
|
45
|
-
if 'Sanity' in stage_name:
|
|
46
|
-
if pkts_received > 0:
|
|
47
|
-
return PERFECT_SCORE, error_msg
|
|
48
|
-
else:
|
|
49
|
-
error_msg = 'No advertisements were received from the gateway.'
|
|
50
|
-
return MINIMUM_SCORE, error_msg
|
|
51
|
-
else:
|
|
52
|
-
if rsquared > 0.7 and slope > 0:
|
|
53
|
-
return PERFECT_SCORE, error_msg
|
|
54
|
-
elif rsquared > 0.5 and slope > 0:
|
|
55
|
-
error_msg = "The correlation between 'txMaxDuration' and the board advertisements is suboptimal."
|
|
56
|
-
return INCONCLUSIVE_MINIMUM, error_msg
|
|
57
|
-
else:
|
|
58
|
-
error_msg = "The correlation between 'txMaxDuration' and the board advertisements is weak."
|
|
59
|
-
return MINIMUM_SCORE, error_msg
|
|
60
|
-
|
|
61
|
-
@staticmethod
|
|
62
|
-
def calc_for_test(test, stage) -> int:
|
|
63
|
-
# Some stages shouldn't affect test score
|
|
64
|
-
if 'Geolocation' in stage.stage_name or 'info' in stage.result_indication:
|
|
65
|
-
return test.test_pass
|
|
66
|
-
|
|
67
|
-
if stage.score_inconclusive() and test.score_pass():
|
|
68
|
-
return test.inconclusive_min
|
|
69
|
-
elif stage.score_fail():
|
|
70
|
-
return MINIMUM_SCORE
|
|
71
|
-
else:
|
|
72
|
-
return test.test_pass
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
class GenericTest:
|
|
76
|
-
def __init__(self, mqttc: MqttClient,
|
|
77
|
-
gw_capabilities:GWCapabilities, gw_id, owner_id, test_name, ble_sim: BLESimulator = None, **kwargs):
|
|
78
|
-
# Clients
|
|
79
|
-
self.mqttc = mqttc
|
|
80
|
-
self.ble_sim = ble_sim
|
|
81
|
-
|
|
82
|
-
# Test-Related
|
|
83
|
-
self.gw_capabilities = gw_capabilities
|
|
84
|
-
self.report = ''
|
|
85
|
-
self.report_html = ''
|
|
86
|
-
self.test_pass = PERFECT_SCORE
|
|
87
|
-
self.pass_min = PASS_MINIMUM
|
|
88
|
-
self.inconclusive_min = INCONCLUSIVE_MINIMUM
|
|
89
|
-
self.start_time = None
|
|
90
|
-
self.duration = None
|
|
91
|
-
self.test_name = test_name
|
|
92
|
-
self.test_dir = os.path.join(self.certificate_dir, self.test_name)
|
|
93
|
-
self.env_dirs.create_dir(self.test_dir)
|
|
94
|
-
self.stages = []
|
|
95
|
-
self.test_tooltip = kwargs.get('test_tooltip', 'Missing tooltip')
|
|
96
|
-
self.result_indication = kwargs.get('result_indication', SCORE_BASED)
|
|
97
|
-
self.rc = TEST_PASSED
|
|
98
|
-
|
|
99
|
-
def __repr__(self):
|
|
100
|
-
return self.test_name
|
|
101
|
-
|
|
102
|
-
def prepare_test(self):
|
|
103
|
-
pass
|
|
104
|
-
|
|
105
|
-
def run(self):
|
|
106
|
-
self.start_time = datetime.datetime.now()
|
|
107
|
-
debug_print(f"Starting Test {self.test_name} : {self.start_time}")
|
|
108
|
-
|
|
109
|
-
def runtime(self):
|
|
110
|
-
return datetime.datetime.now() - self.start_time
|
|
111
|
-
|
|
112
|
-
def add_to_test_report(self, report):
|
|
113
|
-
self.report += '\n' + report
|
|
114
|
-
|
|
115
|
-
def create_test_html(self):
|
|
116
|
-
self.report_html = self.template_engine.render_template('test.html', test=self,
|
|
117
|
-
running_time = self.runtime())
|
|
118
|
-
|
|
119
|
-
def end_test(self):
|
|
120
|
-
self.determine_rc()
|
|
121
|
-
for stage in self.stages:
|
|
122
|
-
stage.determine_rc()
|
|
123
|
-
self.duration = self.runtime()
|
|
124
|
-
self.create_test_html()
|
|
125
|
-
|
|
126
|
-
def score_pass(self):
|
|
127
|
-
if self.test_pass >= self.pass_min:
|
|
128
|
-
return True
|
|
129
|
-
return False
|
|
130
|
-
|
|
131
|
-
def score_inconclusive(self):
|
|
132
|
-
if self.inconclusive_min <= self.test_pass < self.pass_min:
|
|
133
|
-
return True
|
|
134
|
-
return False
|
|
135
|
-
|
|
136
|
-
def score_fail(self):
|
|
137
|
-
if self.test_pass < self.inconclusive_min:
|
|
138
|
-
return True
|
|
139
|
-
return False
|
|
140
|
-
|
|
141
|
-
def determine_rc(self):
|
|
142
|
-
# Set test rc - defaults to TEST_PASSED (rc=0)
|
|
143
|
-
if self.result_indication == 'info':
|
|
144
|
-
if self.score_pass():
|
|
145
|
-
self.rc = TEST_INFO
|
|
146
|
-
else:
|
|
147
|
-
self.rc = TEST_WARNING
|
|
148
|
-
elif self.result_indication == 'optional':
|
|
149
|
-
self.rc = TEST_OPTIONAL
|
|
150
|
-
else:
|
|
151
|
-
if self.score_inconclusive():
|
|
152
|
-
self.rc = TEST_INCONCLUSIVE
|
|
153
|
-
elif self.score_fail():
|
|
154
|
-
self.rc = TEST_FAILED
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
class GenericStage():
|
|
158
|
-
def __init__(self, stage_name, **kwargs):
|
|
159
|
-
#Stage Params
|
|
160
|
-
self.stage_name = stage_name
|
|
161
|
-
self.result_indication = kwargs.get('result_indication', SCORE_BASED)
|
|
162
|
-
self.stage_pass = MINIMUM_SCORE
|
|
163
|
-
self.pass_min = kwargs.get('pass_min', PASS_MINIMUM)
|
|
164
|
-
self.inconclusive_min = kwargs.get('inconclusive_min', INCONCLUSIVE_MINIMUM)
|
|
165
|
-
self.report = ''
|
|
166
|
-
self.report_html = ''
|
|
167
|
-
self.start_time = None
|
|
168
|
-
self.duration = None
|
|
169
|
-
self.csv_path = os.path.join(self.test_dir, f'{self.stage_name}.csv')
|
|
170
|
-
self.stage_tooltip = kwargs.get('stage_tooltip', 'Missing tooltip')
|
|
171
|
-
self.error_summary = kwargs.get('error_summary', ERR_SUMMARY_DEFAULT)
|
|
172
|
-
self.rc = TEST_PASSED
|
|
173
|
-
|
|
174
|
-
def __repr__(self):
|
|
175
|
-
return self.stage_name
|
|
176
|
-
|
|
177
|
-
def prepare_stage(self):
|
|
178
|
-
debug_print(f'### Starting Stage: {self.stage_name}')
|
|
179
|
-
|
|
180
|
-
def run(self):
|
|
181
|
-
self.start_time = datetime.datetime.now()
|
|
182
|
-
|
|
183
|
-
def add_to_stage_report(self, report):
|
|
184
|
-
self.report += f'{report}\n'
|
|
185
|
-
|
|
186
|
-
def generate_stage_report(self):
|
|
187
|
-
return self.report
|
|
188
|
-
|
|
189
|
-
def add_report_line_separator(self):
|
|
190
|
-
self.add_to_stage_report('-' * 50)
|
|
191
|
-
|
|
192
|
-
def add_report_header(self):
|
|
193
|
-
uncapitalize = lambda s: s[:1].lower() + s[1:] if s else ''
|
|
194
|
-
self.duration = datetime.datetime.now() - self.start_time
|
|
195
|
-
self.add_to_stage_report(f'Stage run time: {self.duration}')
|
|
196
|
-
self.add_to_stage_report(f'This stage {uncapitalize(self.stage_tooltip)}.')
|
|
197
|
-
self.add_report_line_separator()
|
|
198
|
-
|
|
199
|
-
def add_report_topic_validation(self, topic:Literal['status', 'data']):
|
|
200
|
-
pass
|
|
201
|
-
# Pass until validated
|
|
202
|
-
if self.topic_suffix != '':
|
|
203
|
-
return
|
|
204
|
-
valid_topic, invalid_msg, invalid_topic = self.mqttc.validate_serialization_topic(topic)
|
|
205
|
-
if valid_topic == False:
|
|
206
|
-
# For now not failing stage since the customBroker command include topics explicitly
|
|
207
|
-
# self.stage_pass = MINIMUM_SCORE
|
|
208
|
-
# self.error_summary += "Invalid serialization-topic combination. "
|
|
209
|
-
self.add_to_stage_report(f'Note: Received message on {invalid_topic} although serialization is {self.mqttc.get_serialization()}')
|
|
210
|
-
self.add_report_line_separator()
|
|
211
|
-
|
|
212
|
-
def score_pass(self):
|
|
213
|
-
if self.stage_pass >= self.pass_min:
|
|
214
|
-
return True
|
|
215
|
-
return False
|
|
216
|
-
|
|
217
|
-
def score_inconclusive(self):
|
|
218
|
-
if self.inconclusive_min <= self.stage_pass < self.pass_min:
|
|
219
|
-
return True
|
|
220
|
-
return False
|
|
221
|
-
|
|
222
|
-
def score_fail(self):
|
|
223
|
-
if self.stage_pass < self.inconclusive_min:
|
|
224
|
-
return True
|
|
225
|
-
return False
|
|
226
|
-
|
|
227
|
-
def determine_rc(self):
|
|
228
|
-
# Set stage rc - defaults to TEST_PASSED (rc=0)
|
|
229
|
-
if self.result_indication == 'info':
|
|
230
|
-
if self.score_pass():
|
|
231
|
-
self.rc = TEST_INFO
|
|
232
|
-
else:
|
|
233
|
-
self.rc = TEST_WARNING
|
|
234
|
-
else:
|
|
235
|
-
if self.score_inconclusive():
|
|
236
|
-
self.rc = TEST_INCONCLUSIVE
|
|
237
|
-
elif self.score_fail():
|
|
238
|
-
self.rc = TEST_FAILED
|