wiliot-certificate 4.5.0__py3-none-any.whl → 4.5.0a2__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.
- certificate/ag/wlt_types_ag_jsons/brg2brg_ota.json +211 -0
- certificate/ag/wlt_types_ag_jsons/brg2gw_hb.json +894 -0
- certificate/ag/wlt_types_ag_jsons/brg2gw_hb_sleep.json +184 -0
- certificate/ag/wlt_types_ag_jsons/calibration.json +490 -0
- certificate/ag/wlt_types_ag_jsons/custom.json +614 -0
- certificate/ag/wlt_types_ag_jsons/datapath.json +900 -0
- certificate/ag/wlt_types_ag_jsons/energy2400.json +670 -0
- certificate/ag/wlt_types_ag_jsons/energySub1g.json +691 -0
- certificate/ag/wlt_types_ag_jsons/externalSensor.json +727 -0
- certificate/ag/wlt_types_ag_jsons/interface.json +1095 -0
- certificate/ag/wlt_types_ag_jsons/powerManagement.json +1439 -0
- certificate/ag/wlt_types_ag_jsons/side_info_sensor.json +105 -0
- certificate/ag/wlt_types_ag_jsons/signal_indicator_data.json +77 -0
- certificate/ag/wlt_types_ag_jsons/unified_echo_ext_pkt.json +126 -0
- certificate/ag/wlt_types_ag_jsons/unified_echo_pkt.json +175 -0
- certificate/ag/wlt_types_ag_jsons/unified_sensor_pkt.json +65 -0
- certificate/cert_common.py +35 -65
- certificate/cert_config.py +18 -43
- certificate/cert_data_sim.py +9 -12
- certificate/cert_defines.py +0 -8
- certificate/cert_gw_sim.py +7 -32
- certificate/cert_mqtt.py +5 -15
- certificate/cert_prints.py +0 -1
- certificate/cert_results.py +37 -48
- certificate/cert_utils.py +15 -24
- certificate/certificate.py +5 -12
- certificate/certificate_cli.py +13 -10
- certificate/certificate_eth_test_list.txt +3 -4
- certificate/certificate_sanity_test_list.txt +2 -3
- certificate/certificate_test_list.txt +4 -4
- certificate/tests/calibration/interval_test/interval_test.json +0 -1
- certificate/tests/calibration/output_power_test/output_power_test.json +0 -1
- certificate/tests/calibration/pattern_test/pattern_test.json +0 -1
- certificate/tests/cloud_connectivity/acl_ext_adv_test/acl_ext_adv_test.json +0 -1
- certificate/tests/cloud_connectivity/acl_test/acl_test.json +0 -1
- certificate/tests/cloud_connectivity/acl_test/acl_test.py +15 -13
- certificate/tests/cloud_connectivity/brg_ota_test/brg_ota_test.json +1 -2
- certificate/tests/cloud_connectivity/brg_ota_test/brg_ota_test.py +6 -8
- certificate/tests/cloud_connectivity/channel_scan_behaviour_test/channel_scan_behaviour_test.json +0 -1
- certificate/tests/cloud_connectivity/channel_scan_behaviour_test/channel_scan_behaviour_test.py +3 -3
- certificate/tests/cloud_connectivity/connection_test/connection_test.json +0 -1
- certificate/tests/cloud_connectivity/connection_test/connection_test.py +13 -6
- certificate/tests/cloud_connectivity/deduplication_test/deduplication_test.json +0 -1
- certificate/tests/cloud_connectivity/deduplication_test/deduplication_test.py +11 -6
- certificate/tests/cloud_connectivity/downlink_test/downlink_test.json +0 -1
- certificate/tests/cloud_connectivity/downlink_test/downlink_test.py +4 -1
- certificate/tests/cloud_connectivity/ext_adv_stress_test/ext_adv_stress_test.json +0 -1
- certificate/tests/cloud_connectivity/ext_adv_stress_test/ext_adv_stress_test.py +9 -14
- certificate/tests/cloud_connectivity/reboot_test/reboot_test.json +0 -1
- certificate/tests/cloud_connectivity/reboot_test/reboot_test.py +0 -2
- certificate/tests/cloud_connectivity/registration_test/registration_test.json +0 -1
- certificate/tests/cloud_connectivity/registration_test/registration_test_cli.py +1 -1
- certificate/tests/cloud_connectivity/stress_test/stress_test.json +0 -1
- certificate/tests/cloud_connectivity/stress_test/stress_test.py +11 -15
- certificate/tests/cloud_connectivity/uplink_ext_adv_test/uplink_ext_adv_test.json +0 -1
- certificate/tests/cloud_connectivity/uplink_ext_adv_test/uplink_ext_adv_test.py +2 -1
- certificate/tests/cloud_connectivity/uplink_test/uplink_test.json +0 -1
- certificate/tests/cloud_connectivity/uplink_test/uplink_test.py +20 -27
- certificate/tests/datapath/aging_test/aging_test.json +0 -1
- certificate/tests/datapath/aging_test/aging_test.py +3 -7
- certificate/tests/datapath/event_ble5_test/event_ble5_test.json +2 -3
- certificate/tests/datapath/event_ble5_test/event_ble5_test.py +13 -7
- certificate/tests/datapath/event_test/event_test.json +2 -3
- certificate/tests/datapath/event_test/event_test.py +10 -5
- certificate/tests/datapath/num_of_tags_test/num_of_tags_test.json +1 -2
- certificate/tests/datapath/num_of_tags_test/num_of_tags_test.py +5 -9
- certificate/tests/datapath/output_power_test/output_power_test.json +0 -1
- certificate/tests/datapath/pacer_interval_ble5_test/pacer_interval_ble5_test.json +0 -1
- certificate/tests/datapath/pacer_interval_ble5_test/pacer_interval_ble5_test.py +4 -4
- certificate/tests/datapath/pacer_interval_test/pacer_interval_test.json +0 -1
- certificate/tests/datapath/pattern_test/pattern_test.json +0 -1
- certificate/tests/datapath/pkt_filter_ble5_chl21_test/pkt_filter_ble5_chl21_test.json +0 -1
- certificate/tests/datapath/pkt_filter_ble5_chl21_test/pkt_filter_ble5_chl21_test.py +5 -5
- certificate/tests/datapath/pkt_filter_ble5_test/pkt_filter_ble5_test.json +0 -1
- certificate/tests/datapath/pkt_filter_ble5_test/pkt_filter_ble5_test.py +5 -5
- certificate/tests/datapath/pkt_filter_brg2gw_ext_adv_test/pkt_filter_brg2gw_ext_adv_test.json +0 -1
- certificate/tests/datapath/pkt_filter_brg2gw_ext_adv_test/pkt_filter_brg2gw_ext_adv_test.py +8 -10
- certificate/tests/datapath/pkt_filter_gen3_test/pkt_filter_gen3_test.json +0 -1
- certificate/tests/datapath/pkt_filter_test/pkt_filter_test.json +0 -1
- certificate/tests/datapath/rssi_threshold_test/rssi_threshold_test.json +0 -1
- certificate/tests/datapath/rx_channel_hopping_test/rx_channel_hopping_test.json +0 -1
- certificate/tests/datapath/rx_channel_test/rx_channel_test.json +0 -1
- certificate/tests/datapath/rx_rate_gen2_test/rx_rate_gen2_test.json +0 -1
- certificate/tests/datapath/rx_rate_gen2_test/rx_rate_gen2_test.py +1 -1
- certificate/tests/datapath/rx_rate_gen3_test/rx_rate_gen3_test.json +0 -1
- certificate/tests/datapath/stress_gen3_test/stress_gen3_test.json +0 -1
- certificate/tests/datapath/stress_gen3_test/stress_gen3_test.py +0 -3
- certificate/tests/datapath/stress_test/stress_test.json +0 -1
- certificate/tests/datapath/stress_test/stress_test.py +0 -3
- certificate/tests/datapath/tx_repetition_test/tx_repetition_test.json +0 -1
- certificate/tests/edge_mgmt/action_blink_test/action_blink_test.json +0 -1
- certificate/tests/edge_mgmt/action_get_battery_sensor_test/action_get_battery_sensor_test.json +0 -1
- certificate/tests/edge_mgmt/action_get_module_test/action_get_module_test.json +0 -1
- certificate/tests/edge_mgmt/action_get_pof_data_test/action_get_pof_data_test.json +0 -1
- certificate/tests/edge_mgmt/action_gw_hb_test/action_gw_hb_test.json +0 -1
- certificate/tests/edge_mgmt/action_reboot_test/action_reboot_test.json +0 -1
- certificate/tests/edge_mgmt/action_restore_defaults_test/action_restore_defaults_test.json +0 -1
- certificate/tests/edge_mgmt/action_send_hb_test/action_send_hb_test.json +0 -1
- certificate/tests/edge_mgmt/action_send_hb_test/action_send_hb_test.py +14 -18
- certificate/tests/edge_mgmt/periodic_msgs_test/periodic_msgs_test.json +0 -1
- certificate/tests/energy2400/duty_cycle_test/duty_cycle_test.json +0 -1
- certificate/tests/energy2400/output_power_test/output_power_test.json +0 -1
- certificate/tests/energy2400/pattern_test/pattern_test.json +0 -1
- certificate/tests/energy2400/signal_indicator_ble5_test/signal_indicator_ble5_test.json +0 -1
- certificate/tests/energy2400/signal_indicator_ble5_test/signal_indicator_ble5_test.py +3 -4
- certificate/tests/energy2400/signal_indicator_ext_adv_test/signal_indicator_ext_adv_test.json +9 -9
- certificate/tests/energy2400/signal_indicator_ext_adv_test/signal_indicator_ext_adv_test.py +271 -113
- certificate/tests/energy2400/signal_indicator_test/signal_indicator_test.json +0 -1
- certificate/tests/energy2400/signal_indicator_test/signal_indicator_test.py +1 -1
- certificate/tests/energy_sub1g/duty_cycle_test/duty_cycle_test.json +0 -1
- certificate/tests/energy_sub1g/pattern_test/pattern_test.json +0 -1
- certificate/tests/pwr_mgmt/pwr_mgmt_test/pwr_mgmt_test.json +0 -1
- certificate/tests/sensors/ext_sensor_test/ext_sensor_test.json +0 -1
- certificate/tests/sensors/ext_sensor_test/ext_sensor_test.py +9 -4
- common/api_if/api_validation.py +0 -6
- common/web/templates/generator.html +79 -141
- common/web/web_utils.py +56 -78
- gui_certificate/server.py +78 -283
- gui_certificate/templates/cert_run.html +113 -179
- {wiliot_certificate-4.5.0.dist-info → wiliot_certificate-4.5.0a2.dist-info}/METADATA +22 -7
- {wiliot_certificate-4.5.0.dist-info → wiliot_certificate-4.5.0a2.dist-info}/RECORD +125 -109
- {wiliot_certificate-4.5.0.dist-info → wiliot_certificate-4.5.0a2.dist-info}/WHEEL +0 -0
- {wiliot_certificate-4.5.0.dist-info → wiliot_certificate-4.5.0a2.dist-info}/entry_points.txt +0 -0
- {wiliot_certificate-4.5.0.dist-info → wiliot_certificate-4.5.0a2.dist-info}/licenses/LICENSE +0 -0
- {wiliot_certificate-4.5.0.dist-info → wiliot_certificate-4.5.0a2.dist-info}/top_level.txt +0 -0
|
@@ -5,169 +5,327 @@ import certificate.cert_mqtt as cert_mqtt
|
|
|
5
5
|
import certificate.cert_common as cert_common
|
|
6
6
|
import certificate.cert_config as cert_config
|
|
7
7
|
|
|
8
|
+
# Test Description:
|
|
9
|
+
# This test is to verify the functionality of both signal indicator tx (tx_brg) and rx (rx_brg) at BRG level.
|
|
10
|
+
# We will configure several signal indicator params during the test, and check the functionality of the signal indicator logic
|
|
11
|
+
# for each of them.
|
|
12
|
+
# It is important to execute the test with several setups: 2 Fanstel BRG's, 2 Minew BRG's and 1 Fanstel and 1 Minew BRG.
|
|
13
|
+
# At first, we will configure several tx signal indicator params and check for ack's, to verify all indicated params were
|
|
14
|
+
# received at the cloud.
|
|
15
|
+
# Then, we will examine the signal indicator end-2-end logic with both transmitter and receiver:
|
|
16
|
+
# phase 1 - One BRG will be configured as signal indicator tx, and the other as signal indicator rx, and we expect to see
|
|
17
|
+
# signal indicator packets only from the tx BRG, and according to the tx params (to check the repetition and cycle params).
|
|
18
|
+
# phase 2 - Same as phase 1, but with different tx params configured.
|
|
19
|
+
# phase 3 - One rx BRG without any tx BRG. We don't expect to see any signal indicator packets. This phase is to verify the
|
|
20
|
+
# brg module logic is working properly, and no tag packet is accidentally being treated as signal indicator packet.
|
|
21
|
+
# phase 4 - Both BRG's will be configured to be transmitters and receivers, with different tx params for each one. we expect
|
|
22
|
+
# to see signal indicator packets from both BRG's, according to the tx params.
|
|
23
|
+
# phase 5 - One BRG will be configured as signal indicator tx, but no rx, so we don't expect to receive signal indicatopr packets.
|
|
24
|
+
# that way we can assure the logic within the receiver is not confused by the signal indicator uuid as external sensor.
|
|
25
|
+
|
|
26
|
+
|
|
8
27
|
# Test MACROS #
|
|
9
28
|
NUM_OF_SCANNING_CYCLE = 5
|
|
29
|
+
DEFAULT_SCAN_TIME = 30
|
|
10
30
|
SCAN_DELAY_TIME = 3
|
|
31
|
+
BLE5_MAX_DURATION_SEC = ag.BLE5_PARAM_PRIMARY_CHANNEL_SCAN_CYCLE // 1000 + 1
|
|
11
32
|
|
|
12
33
|
|
|
13
|
-
def
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
34
|
+
def test_rssi_threshold(test):
|
|
35
|
+
cycle, rep = 5, 4
|
|
36
|
+
rx_brg_ = test.brg1 # when internal_brg test this is the internal_brg
|
|
37
|
+
tx_brg_ = cert_config.get_brg_by_target(test, DUT)
|
|
38
|
+
rssi_threshold = -25
|
|
18
39
|
|
|
19
|
-
|
|
20
|
-
# configuring
|
|
21
|
-
utPrint(f"Configuring
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
40
|
+
utPrint(f"TX BRG with RX- cycle = {cycle}, repetition = {rep}\n", "BLUE")
|
|
41
|
+
# configuring receiver #
|
|
42
|
+
utPrint(f"Configuring BRG {rx_brg_.id_str} as Signal Indicator Receiver with RSSI Threshold of {rssi_threshold}", "BOLD")
|
|
43
|
+
is_ble5 = not test.internal_brg
|
|
44
|
+
test = cert_config.brg_configure(test=test, module=rx_brg_.sensors,
|
|
45
|
+
fields=[BRG_SENSOR0, BRG_RSSI_THRESHOLD],
|
|
46
|
+
values=[ag.EXTERNAL_SENSORS_SIGNAL_INDICATOR, rssi_threshold],
|
|
47
|
+
ble5=is_ble5, wait=True, target=BRG1)[0]
|
|
25
48
|
if test.rc == TEST_FAILED:
|
|
26
|
-
test.add_reason(f"
|
|
49
|
+
test.add_reason(f"BRG {rx_brg_.id_str}: didn't receive signal indicator receiver configuration!")
|
|
27
50
|
return test
|
|
28
|
-
# configuring
|
|
29
|
-
utPrint(f"Configuring
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
values=[
|
|
51
|
+
# configuring transmitter #
|
|
52
|
+
utPrint(f"Configuring BRG {tx_brg_.id_str} as Signal Indicator Transmitter", "BOLD")
|
|
53
|
+
wait = not test.internal_brg
|
|
54
|
+
test = cert_config.brg_configure(test=test, module=tx_brg_.energy2400, fields=[BRG_SIGNAL_INDICATOR_CYCLE, BRG_SIGNAL_INDICATOR_REP],
|
|
55
|
+
values=[cycle, rep], ble5=True, wait=wait)[0]
|
|
33
56
|
if test.rc == TEST_FAILED:
|
|
34
|
-
test.add_reason(f"
|
|
57
|
+
test.add_reason(f"BRG {tx_brg_.id_str}: didn't receive signal indicator transmitter configuration!")
|
|
35
58
|
return test
|
|
59
|
+
utPrint(f"BRG {tx_brg_.id_str} configured to be transmitter - cycle = {cycle},"
|
|
60
|
+
f"repetition = {rep}", "BOLD")
|
|
61
|
+
# phase analysis #
|
|
62
|
+
print_update_wait(BLE5_MAX_DURATION_SEC) # BLE5 configuration can take up to BLE5_MAX_DURATION_SEC
|
|
63
|
+
cert_mqtt.mqtt_scan_n_create_log_file(test, (NUM_OF_SCANNING_CYCLE * cycle) + SCAN_DELAY_TIME, "rssi_threshold")
|
|
64
|
+
received_signal_ind_pkts = cert_common.get_all_sig_ind_pkts(test=test, rx_brg=rx_brg_, tx_brg=tx_brg_)
|
|
65
|
+
for p in received_signal_ind_pkts:
|
|
66
|
+
print(f"rssi value: {p[UNIFIED_SENSOR_PKT].pkt.rssi}")
|
|
67
|
+
rssi_threshold_viloation_pkts = [p for p in received_signal_ind_pkts if p[UNIFIED_SENSOR_PKT].pkt.rssi >= -1 * rssi_threshold]
|
|
68
|
+
if rssi_threshold_viloation_pkts:
|
|
69
|
+
test.rc = TEST_FAILED
|
|
70
|
+
test.add_reason(f"rssi_threshold phase failed - BRG {rx_brg_.id_str} echoed"
|
|
71
|
+
f" {len(rssi_threshold_viloation_pkts)} signal indicator packets\n with RSSI weaker than {rssi_threshold}")
|
|
72
|
+
return test
|
|
73
|
+
|
|
74
|
+
|
|
75
|
+
def test_brg0_tx_brg1_rx(test):
|
|
76
|
+
|
|
77
|
+
tx_brg_ = cert_config.get_brg_by_target(test, DUT)
|
|
78
|
+
rx_brg_ = test.brg1 # when internal_brg test this is the internal_brg
|
|
79
|
+
cycle, rep = 8, 4
|
|
36
80
|
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
81
|
+
utPrint(f"TX BRG with RX- cycle = {cycle}, repetition = {rep}\n", "BLUE")
|
|
82
|
+
# configuring receiver #
|
|
83
|
+
utPrint(f"Configuring BRG {rx_brg_.id_str} as Signal Indicator Receiver", "BOLD")
|
|
84
|
+
is_ble5 = not test.internal_brg
|
|
85
|
+
test = cert_config.brg_configure(test=test, module=rx_brg_.sensors,
|
|
86
|
+
fields=[BRG_SENSOR0],
|
|
87
|
+
values=[ag.EXTERNAL_SENSORS_SIGNAL_INDICATOR],
|
|
88
|
+
ble5=is_ble5, wait=True, target=BRG1)[0]
|
|
41
89
|
if test.rc == TEST_FAILED:
|
|
42
|
-
test.add_reason(f"
|
|
90
|
+
test.add_reason(f"BRG {rx_brg_.id_str}: didn't receive signal indicator receiver configuration!")
|
|
43
91
|
return test
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
92
|
+
# configuring transmitter #
|
|
93
|
+
wait = not test.internal_brg
|
|
94
|
+
utPrint(f"Configuring BRG {tx_brg_.id_str} as Signal Indicator Transmitter", "BOLD")
|
|
95
|
+
test = cert_config.brg_configure(test=test, module=tx_brg_.energy2400,
|
|
96
|
+
fields=[BRG_SIGNAL_INDICATOR_CYCLE, BRG_SIGNAL_INDICATOR_REP],
|
|
97
|
+
values=[cycle, rep], ble5=True, wait=wait)[0]
|
|
47
98
|
if test.rc == TEST_FAILED:
|
|
48
|
-
test.add_reason(f"
|
|
99
|
+
test.add_reason(f"BRG {tx_brg_.id_str}: didn't receive signal indicator transmitter configuration!")
|
|
49
100
|
return test
|
|
50
|
-
|
|
101
|
+
utPrint(f"BRG {tx_brg_.id_str} configured to be transmitter - cycle = {cycle},"
|
|
102
|
+
f"repetition = {rep}", "BOLD")
|
|
51
103
|
# phase analysis #
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
104
|
+
print_update_wait(BLE5_MAX_DURATION_SEC) # BLE5 configuration can take up to BLE5_MAX_DURATION_SEC
|
|
105
|
+
cert_mqtt.mqtt_scan_n_create_log_file(test, (NUM_OF_SCANNING_CYCLE * cycle) + SCAN_DELAY_TIME, f"brg0_rx_brg1_tx_{cycle}_{rep}")
|
|
106
|
+
received_signal_ind_pkts = cert_common.get_all_sig_ind_pkts(test=test, rx_brg=rx_brg_, tx_brg=tx_brg_)
|
|
107
|
+
|
|
108
|
+
if cert_common.sig_ind_pkts_fail_analysis(tx_brg_, rx_brg_, NUM_OF_SCANNING_CYCLE, received_signal_ind_pkts):
|
|
56
109
|
test.rc = TEST_FAILED
|
|
57
|
-
expected_signal_ind_pkts = cert_common.exp_sig_ind_pkts2(
|
|
58
|
-
test.add_reason(f"
|
|
59
|
-
f"signal indicator packets\nreceived {len(
|
|
110
|
+
expected_signal_ind_pkts = cert_common.exp_sig_ind_pkts2(tx_brg_, rx_brg_, NUM_OF_SCANNING_CYCLE)
|
|
111
|
+
test.add_reason(f"brg0_rx_brg1_tx phase failed - BRG {rx_brg_.id_str} received wrong number of "
|
|
112
|
+
f"signal indicator packets\nreceived {len(received_signal_ind_pkts)} packets, "
|
|
60
113
|
f"expected {expected_signal_ind_pkts} packets")
|
|
61
|
-
print(
|
|
62
|
-
print([[p[TIMESTAMP], p[UNIFIED_SENSOR_PKT].pkt.signal_indicator_payload.rx_antenna] for p in
|
|
114
|
+
print(received_signal_ind_pkts) # TODO: logging print(debug)
|
|
115
|
+
print([[p[TIMESTAMP], p[UNIFIED_SENSOR_PKT].pkt.signal_indicator_payload.rx_antenna] for p in received_signal_ind_pkts])
|
|
116
|
+
|
|
117
|
+
test = cert_common.rx_tx_antenna_check(test, received_signal_ind_pkts, tx_brg_, rx_brg_, NUM_OF_SCANNING_CYCLE)
|
|
118
|
+
test = cert_common.output_power_check(test, received_signal_ind_pkts, tx_brg_)
|
|
119
|
+
test = cert_common.rssi_check(test, received_signal_ind_pkts)
|
|
120
|
+
|
|
121
|
+
return test
|
|
122
|
+
|
|
123
|
+
|
|
124
|
+
def test_brg0_none_brg1_rx(test):
|
|
125
|
+
cycle, rep = ag.BRG_DEFAULT_SIGNAL_INDICATOR_CYCLE, ag.BRG_DEFAULT_SIGNAL_INDICATOR_REP
|
|
126
|
+
tx_brg_ = cert_config.get_brg_by_target(test, DUT)
|
|
127
|
+
rx_brg_ = test.brg1 # when internal_brg test this is the internal_brg
|
|
128
|
+
utPrint(f"RX BRG without TX- cycle = {cycle}, repetition = {rep}\n", "BLUE")
|
|
129
|
+
# configuring receiver #
|
|
130
|
+
utPrint(f"Configuring BRG {rx_brg_.id_str} as Signal Indicator Receiver", "BOLD")
|
|
131
|
+
is_ble5 = not test.internal_brg
|
|
132
|
+
test = cert_config.brg_configure(test=test, module=rx_brg_.sensors,
|
|
133
|
+
fields=[BRG_SENSOR0],
|
|
134
|
+
values=[ag.EXTERNAL_SENSORS_SIGNAL_INDICATOR],
|
|
135
|
+
ble5=is_ble5, wait=True, target=BRG1)[0]
|
|
136
|
+
if test.rc == TEST_FAILED:
|
|
137
|
+
test.add_reason(f"BRG {rx_brg_.id_str}: didn't receive signal indicator receiver configuration!")
|
|
63
138
|
return test
|
|
139
|
+
utPrint(f"BRG {rx_brg_.id_str} successfully configured as Signal Indicator Receiver\n", "BOLD")
|
|
64
140
|
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
141
|
+
# phase analysis #
|
|
142
|
+
print_update_wait(BLE5_MAX_DURATION_SEC) # BLE5 configuration can take up to BLE5_MAX_DURATION_SEC
|
|
143
|
+
cert_mqtt.mqtt_scan_n_create_log_file(test, DEFAULT_SCAN_TIME, "brg0_none_brg1_rx")
|
|
144
|
+
expected_signal_ind_pkts = [0]
|
|
145
|
+
received_signal_ind_pkts = cert_common.get_all_sig_ind_pkts(test=test, rx_brg=rx_brg_, tx_brg=tx_brg_)
|
|
146
|
+
if len(received_signal_ind_pkts) not in expected_signal_ind_pkts:
|
|
147
|
+
test.rc = TEST_FAILED
|
|
148
|
+
test.add_reason(f"brg0_rx_brg1_tx phase failed - BRG {rx_brg_.id_str} received wrong number of "
|
|
149
|
+
f"signal indicator packets\n received {len(received_signal_ind_pkts)} packets, "
|
|
150
|
+
f"expected {expected_signal_ind_pkts} packets")
|
|
68
151
|
|
|
69
152
|
return test
|
|
70
153
|
|
|
71
154
|
|
|
72
|
-
def
|
|
155
|
+
def test_brg0_rxtx_brg1_rxtx(test):
|
|
73
156
|
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
157
|
+
if test.internal_brg:
|
|
158
|
+
# Can't scan on ble5 with internal brg because config won't be received
|
|
159
|
+
test.add_reason("skip for internal BRG")
|
|
160
|
+
test.rc = TEST_SKIPPED
|
|
161
|
+
return test
|
|
77
162
|
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
163
|
+
tx_cycle, tx_rep = 5, 4
|
|
164
|
+
rx_cycle, rx_rep = 5, 4
|
|
165
|
+
tx_brg_ = cert_config.get_brg_by_target(test, DUT)
|
|
166
|
+
rx_brg_ = test.brg1
|
|
167
|
+
utPrint("Both BRG's are transmitter and receivers, with different values\n", "BLUE")
|
|
168
|
+
# configuring first brg (tx_brg_) as receiver
|
|
169
|
+
utPrint(f"Configuring BRG {tx_brg_.id_str} as Signal Indicator Receiver", "BOLD")
|
|
170
|
+
test = cert_config.brg_configure(test=test, module=tx_brg_.sensors, fields=[BRG_SENSOR0],
|
|
171
|
+
values=[ag.EXTERNAL_SENSORS_SIGNAL_INDICATOR], ble5=True)[0]
|
|
172
|
+
if test.rc == TEST_FAILED and test.exit_on_param_failure:
|
|
173
|
+
test.add_reason(f"BRG {tx_brg_.id_str}: didn't receive signal indicator receiver configuration!")
|
|
86
174
|
return test
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
values=[
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
test.add_reason(f"DUT BRG {dut.id_str}: didn't receive extended advertising and rx channel configuration!")
|
|
175
|
+
utPrint(f"BRG {tx_brg_.id_str} successfully configured as Signal Indicator Receiver\n", "BOLD")
|
|
176
|
+
# configuring first brg (tx_brg_) as transmitter
|
|
177
|
+
utPrint(f"Configuring BRG {tx_brg_.id_str} as Signal Indicator Transmitter", "BOLD")
|
|
178
|
+
test = cert_config.brg_configure(test=test, module=tx_brg_.energy2400, fields=[BRG_SIGNAL_INDICATOR_CYCLE, BRG_SIGNAL_INDICATOR_REP],
|
|
179
|
+
values=[tx_cycle, tx_rep], ble5=True)[0]
|
|
180
|
+
if test.rc == TEST_FAILED and test.exit_on_param_failure:
|
|
181
|
+
test.add_reason(f"BRG {tx_brg_.id_str}: didn't receive signal indicator transmitter configuration!")
|
|
95
182
|
return test
|
|
96
|
-
|
|
97
|
-
wait_time_n_print(BLE5_MAX_DURATION_SEC) # BLE5 configuration can take up to BLE5_MAX_DURATION_SEC
|
|
183
|
+
utPrint(f"BRG {tx_brg_.id_str} configured to be transmitter - cycle={tx_cycle}, repetition={tx_rep}", "BOLD")
|
|
98
184
|
|
|
99
|
-
# configuring
|
|
100
|
-
utPrint(f"Configuring
|
|
101
|
-
test = cert_config.brg_configure(test=test, module=
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
185
|
+
# configuring second brg (rx_brg_) as receiver
|
|
186
|
+
utPrint(f"Configuring BRG {rx_brg_.id_str} as Signal Indicator Receiver", "BOLD")
|
|
187
|
+
test = cert_config.brg_configure(test=test, module=rx_brg_.sensors,
|
|
188
|
+
fields=[BRG_SENSOR0],
|
|
189
|
+
values=[ag.EXTERNAL_SENSORS_SIGNAL_INDICATOR],
|
|
190
|
+
ble5=True, target=BRG1)[0]
|
|
191
|
+
if test.rc == TEST_FAILED and test.exit_on_param_failure:
|
|
192
|
+
test.add_reason(f"BRG {rx_brg_.id_str}: didn't receive signal indicator receiver configuration!")
|
|
105
193
|
return test
|
|
106
|
-
utPrint(f"
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
194
|
+
utPrint(f"BRG {rx_brg_.id_str} successfully configured as Signal Indicator Receiver\n", "BOLD")
|
|
195
|
+
|
|
196
|
+
# configuring second brg (rx_brg_) as transmitter (already configured as rx)
|
|
197
|
+
utPrint(f"Configuring BRG {rx_brg_.id_str} as Signal Indicator Transmitter", "BOLD")
|
|
198
|
+
test = cert_config.brg_configure(test=test, module=rx_brg_.energy2400,
|
|
199
|
+
fields=[BRG_SIGNAL_INDICATOR_CYCLE, BRG_SIGNAL_INDICATOR_REP],
|
|
200
|
+
values=[rx_cycle, rx_rep],
|
|
201
|
+
ble5=True, target=BRG1)[0]
|
|
202
|
+
if test.rc == TEST_FAILED and test.exit_on_param_failure:
|
|
203
|
+
test.add_reason(f"BRG {rx_brg_.id_str}: didn't receive signal indicator transmitter configuration!")
|
|
111
204
|
return test
|
|
205
|
+
utPrint(f"BRG {rx_brg_.id_str} configured to be transmitter - cycle={rx_cycle}, repetition={rx_rep}")
|
|
112
206
|
|
|
113
207
|
# phase analysis #
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
208
|
+
print_update_wait(BLE5_MAX_DURATION_SEC) # BLE5 configuration can take up to BLE5_MAX_DURATION_SEC
|
|
209
|
+
cert_mqtt.mqtt_scan_n_create_log_file(test, NUM_OF_SCANNING_CYCLE * max(tx_cycle, rx_cycle) + SCAN_DELAY_TIME, "brg0_rxtx_brg1_rxtx")
|
|
210
|
+
|
|
211
|
+
# Analyzing tx_brg_ performance as receiver
|
|
212
|
+
utPrint(f"Analyzing tx_brg {tx_brg_.id_str} performance as a Receiver\n", "BOLD")
|
|
213
|
+
received_signal_ind_pkts = cert_common.get_all_sig_ind_pkts(test=test, rx_brg=tx_brg_, tx_brg=rx_brg_)
|
|
214
|
+
if cert_common.sig_ind_pkts_fail_analysis(tx_brg_, rx_brg_, NUM_OF_SCANNING_CYCLE, received_signal_ind_pkts):
|
|
215
|
+
test.rc = TEST_FAILED
|
|
216
|
+
expected_signal_ind_pkts = cert_common.exp_sig_ind_pkts2(tx_brg_, rx_brg_, NUM_OF_SCANNING_CYCLE)
|
|
217
|
+
test.add_reason(f"brg0_rxtx_brg1_rxtx phase failed - BRG {tx_brg_.id_str} received wrong number of "
|
|
218
|
+
f"signal indicator packets\nreceived {len(received_signal_ind_pkts)} packets, "
|
|
219
|
+
f"expected {expected_signal_ind_pkts} packets")
|
|
220
|
+
print(received_signal_ind_pkts) # TODO: logging print(debug)
|
|
221
|
+
|
|
222
|
+
# Analyzing rx_brg_ performance as receiver
|
|
223
|
+
utPrint(f"Analyzing rx_brg {rx_brg_.id_str} performance as a Receiver\n", "BOLD")
|
|
224
|
+
received_signal_ind_pkts = cert_common.get_all_sig_ind_pkts(test=test, rx_brg=rx_brg_, tx_brg=tx_brg_)
|
|
225
|
+
if cert_common.sig_ind_pkts_fail_analysis(tx_brg_, rx_brg_, NUM_OF_SCANNING_CYCLE, received_signal_ind_pkts):
|
|
118
226
|
test.rc = TEST_FAILED
|
|
119
|
-
expected_signal_ind_pkts = cert_common.exp_sig_ind_pkts2(
|
|
120
|
-
test.add_reason(f"
|
|
121
|
-
f"signal indicator packets\
|
|
227
|
+
expected_signal_ind_pkts = cert_common.exp_sig_ind_pkts2(tx_brg_, rx_brg_, NUM_OF_SCANNING_CYCLE)
|
|
228
|
+
test.add_reason(f"brg0_rxtx_brg1_rxtx phase failed - BRG {rx_brg_.id_str} received wrong number of "
|
|
229
|
+
f"signal indicator packets\n received {len(received_signal_ind_pkts)} packets, "
|
|
122
230
|
f"expected {expected_signal_ind_pkts} packets")
|
|
123
|
-
print(
|
|
124
|
-
|
|
231
|
+
print(received_signal_ind_pkts) # TODO: logging print(debug)
|
|
232
|
+
# NOTE: We skipped the antenna and output power checks for this phase
|
|
233
|
+
return test
|
|
234
|
+
|
|
235
|
+
|
|
236
|
+
def test_brg0_tx_brg1_none(test):
|
|
237
|
+
# Tx BRG without rx. just waiting for packets to be sent from the transmitter and verify
|
|
238
|
+
# The receiver isn't receiving any signal indicator packets.
|
|
239
|
+
cycle, rep = 4, 3
|
|
240
|
+
tx_brg_ = cert_config.get_brg_by_target(test, DUT)
|
|
241
|
+
rx_brg_ = test.brg1 # when internal_brg test this is the internal_brg
|
|
242
|
+
utPrint(f"TX BRG without RX - cycle = {cycle}, repetition = {rep}\n", "BLUE")
|
|
243
|
+
# configuring transmitter #
|
|
244
|
+
utPrint(f"Configuring BRG {tx_brg_.id_str} as Signal Indicator Transmitter", "BOLD")
|
|
245
|
+
wait = not test.internal_brg
|
|
246
|
+
test = cert_config.brg_configure(test=test, module=tx_brg_.energy2400, fields=[BRG_SIGNAL_INDICATOR_CYCLE, BRG_SIGNAL_INDICATOR_REP],
|
|
247
|
+
values=[cycle, rep], ble5=True, wait=wait)[0]
|
|
248
|
+
if test.rc == TEST_FAILED:
|
|
249
|
+
test.add_reason(f"BRG {tx_brg_.id_str}: didn't receive signal indicator transmitter configuration!")
|
|
125
250
|
return test
|
|
126
251
|
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
252
|
+
# phase analysis #
|
|
253
|
+
print_update_wait(BLE5_MAX_DURATION_SEC) # BLE5 configuration can take up to BLE5_MAX_DURATION_SEC
|
|
254
|
+
cert_mqtt.mqtt_scan_n_create_log_file(test, (NUM_OF_SCANNING_CYCLE * cycle) + SCAN_DELAY_TIME, "brg0_tx_brg1_none")
|
|
255
|
+
expected_signal_ind_pkts = [0]
|
|
256
|
+
received_signal_ind_pkts = cert_common.get_all_sig_ind_pkts(test=test, rx_brg=rx_brg_, tx_brg=tx_brg_)
|
|
257
|
+
if len(received_signal_ind_pkts) not in expected_signal_ind_pkts:
|
|
258
|
+
test.rc = TEST_FAILED
|
|
259
|
+
test.add_reason(f"brg0_tx_brg1_none phase failed - received signal indicator packet from BRG"
|
|
260
|
+
f"{rx_brg_.id_str}")
|
|
261
|
+
test = cert_common.output_power_check(test, received_signal_ind_pkts, tx_brg_)
|
|
130
262
|
|
|
131
263
|
return test
|
|
132
264
|
|
|
133
265
|
|
|
134
|
-
SIGNAL_INDICATOR_TEST_MAP = {"
|
|
266
|
+
SIGNAL_INDICATOR_TEST_MAP = {"rssi_threshold": test_rssi_threshold, "brg0_tx_brg1_rx": test_brg0_tx_brg1_rx,
|
|
267
|
+
"brg0_none_brg1_rx": test_brg0_none_brg1_rx, "brg0_rxtx_brg1_rxtx": test_brg0_rxtx_brg1_rxtx,
|
|
268
|
+
"brg0_tx_brg1_none": test_brg0_tx_brg1_none}
|
|
135
269
|
|
|
136
270
|
|
|
137
271
|
def run(test):
|
|
138
272
|
# Test prolog
|
|
139
273
|
test = cert_common.test_prolog(test)
|
|
140
274
|
|
|
141
|
-
|
|
142
|
-
dut = cert_config.get_brg_by_target(test, DUT)
|
|
143
|
-
tester = cert_config.get_brg_by_target(test, TESTER)
|
|
144
|
-
|
|
145
|
-
for param in test.params:
|
|
146
|
-
phase_run_print(param.name)
|
|
147
|
-
test = SIGNAL_INDICATOR_TEST_MAP[param.value](test)
|
|
148
|
-
cert_mqtt.generate_log_file(test, param.name)
|
|
149
|
-
field_functionality_pass_fail_print(test, param.name)
|
|
150
|
-
test.set_phase_rc(param.name, test.rc)
|
|
151
|
-
test.add_phase_reason(param.name, test.reason)
|
|
275
|
+
for rx_channel in [ag.RX_CHANNEL_10_500K, ag.RX_CHANNEL_37]:
|
|
152
276
|
|
|
277
|
+
# Configure to rx channel and extended advertising pattern
|
|
278
|
+
brg_dut = cert_config.get_brg_by_target(test, DUT)
|
|
279
|
+
test = cert_config.brg_configure(test, fields=[BRG_RX_CHANNEL, BRG_PATTERN],
|
|
280
|
+
values=[rx_channel, ag.DATAPATH_PATTERN_EXTENDED_ADV],
|
|
281
|
+
module=brg_dut.datapath, ble5=True)[0]
|
|
282
|
+
if test.rc == TEST_FAILED:
|
|
283
|
+
return cert_common.test_epilog(test, revert_brgs=True,
|
|
284
|
+
modules=[brg_dut.datapath], ble5=True)
|
|
285
|
+
test = cert_config.brg_configure(test, fields=[BRG_RX_CHANNEL, BRG_PATTERN],
|
|
286
|
+
values=[rx_channel, ag.DATAPATH_PATTERN_EXTENDED_ADV],
|
|
287
|
+
module=test.brg1.datapath, target=BRG1)[0]
|
|
153
288
|
if test.rc == TEST_FAILED:
|
|
289
|
+
return cert_common.test_epilog(test, revert_brgs=True,
|
|
290
|
+
modules=[brg_dut.datapath],
|
|
291
|
+
brg1_modules=[test.brg1.datapath], ble5=True)
|
|
292
|
+
|
|
293
|
+
for param in test.params:
|
|
294
|
+
phase_run_print(param.name)
|
|
295
|
+
test = SIGNAL_INDICATOR_TEST_MAP[param.value](test)
|
|
296
|
+
cert_mqtt.generate_log_file(test, param.name)
|
|
297
|
+
field_functionality_pass_fail_print(test, param.name)
|
|
154
298
|
test.set_phase_rc(param.name, test.rc)
|
|
155
299
|
test.add_phase_reason(param.name, test.reason)
|
|
156
|
-
if test.exit_on_param_failure:
|
|
300
|
+
if test.rc == TEST_FAILED and test.exit_on_param_failure:
|
|
157
301
|
break
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
302
|
+
else:
|
|
303
|
+
test.reset_result()
|
|
304
|
+
|
|
305
|
+
# Reset to defaults after every phase (don't fail the phase on that)
|
|
306
|
+
brg_dut = cert_config.get_brg_by_target(test, DUT)
|
|
307
|
+
test = cert_config.config_brg_defaults(test,
|
|
308
|
+
modules=[brg_dut.energy2400, brg_dut.sensors],
|
|
309
|
+
ble5=True, wait=False)[0]
|
|
310
|
+
# BLE5 configuration can take up to BLE5_MAX_DURATION_SEC, we configured 2 modules here
|
|
311
|
+
print_update_wait(2 * BLE5_MAX_DURATION_SEC)
|
|
312
|
+
if test.rc == TEST_FAILED:
|
|
313
|
+
test.add_reason("Failed to restore brg0 to defaults")
|
|
314
|
+
else:
|
|
315
|
+
test = cert_config.config_brg_defaults(test, modules=[test.brg1.energy2400, test.brg1.sensors], ble5=True, target=BRG1)[0]
|
|
316
|
+
# BLE5 configuration can take up to BLE5_MAX_DURATION_SEC, we configured 2 modules here
|
|
317
|
+
print_update_wait(2 * BLE5_MAX_DURATION_SEC)
|
|
318
|
+
if test.rc == TEST_FAILED:
|
|
319
|
+
test.add_reason("Failed to restore brg0 to defaults")
|
|
320
|
+
if test.rc == TEST_FAILED:
|
|
321
|
+
test.set_phase_rc(param.name, test.rc)
|
|
322
|
+
test.add_phase_reason(param.name, test.reason)
|
|
323
|
+
if test.exit_on_param_failure:
|
|
324
|
+
break
|
|
325
|
+
else:
|
|
326
|
+
test.reset_result()
|
|
172
327
|
|
|
173
|
-
|
|
328
|
+
brg_dut = cert_config.get_brg_by_target(test, DUT)
|
|
329
|
+
return cert_common.test_epilog(test, revert_brgs=True,
|
|
330
|
+
modules=[brg_dut.datapath],
|
|
331
|
+
brg1_modules=[test.brg1.datapath], ble5=True)
|
|
@@ -288,7 +288,7 @@ def test_rx_tx(test):
|
|
|
288
288
|
print(rec_sig_ind_pkts) # TODO: logging print(debug)
|
|
289
289
|
|
|
290
290
|
# Analyzing tester performance as receiver
|
|
291
|
-
utPrint(f"Analyzing DUT {
|
|
291
|
+
utPrint(f"Analyzing DUT {tester.id_str} performance as a Transmitter\n", "BOLD")
|
|
292
292
|
rec_sig_ind_pkts = cert_common.get_all_sig_ind_pkts(test=test, rx_brg=tester, tx_brg=dut)
|
|
293
293
|
if cert_common.sig_ind_pkts_fail_analysis(tx_brg=dut, rx_brg=tester, cycles=NUM_OF_SCANNING_CYCLE, received_pkts=rec_sig_ind_pkts):
|
|
294
294
|
test.rc = TEST_FAILED
|
|
@@ -12,7 +12,6 @@
|
|
|
12
12
|
"multiBridgeTest": 0,
|
|
13
13
|
"gwOnlyTest": 0,
|
|
14
14
|
"dataSimOnlyTest": 0,
|
|
15
|
-
"SupportedFromApiVersion": 12,
|
|
16
15
|
"allSupportedValues": ["SUB1G_ENERGY_PATTERN_NO_ENERGIZING", "SUB1G_ENERGY_PATTERN_SINGLE_TONE_915000",
|
|
17
16
|
"SUB1G_ENERGY_PATTERN_FCC_HOPPING", "SUB1G_ENERGY_PATTERN_JAPAN_1W",
|
|
18
17
|
"SUB1G_ENERGY_PATTERN_JAPAN_350MW", "SUB1G_ENERGY_PATTERN_KOREA",
|
|
@@ -17,6 +17,5 @@
|
|
|
17
17
|
"multiBridgeTest": 0,
|
|
18
18
|
"gwOnlyTest": 0,
|
|
19
19
|
"dataSimOnlyTest": 1,
|
|
20
|
-
"SupportedFromApiVersion": 13,
|
|
21
20
|
"allSupportedValues": ["tag_data_only", "rssi_threshold", "snsr2_unified", "snsr0_no_scrmbl", "snsr1_scrmbl", "snsr0_no_scrmbl_snsr1_scrmbl_snsr2_scrmbl", "snsr0_no_scrmbl_snsr1_scrmbl_snsr2_unified"]
|
|
22
21
|
}
|
|
@@ -413,14 +413,19 @@ EXT_SENSOR_TEST_MAP = {"tag_data_only": test_tag_data_only,
|
|
|
413
413
|
|
|
414
414
|
|
|
415
415
|
def run(test):
|
|
416
|
-
|
|
416
|
+
datapath_module = test.active_brg.datapath
|
|
417
|
+
ext_sensors_module = test.active_brg.sensors
|
|
417
418
|
test = cert_common.test_prolog(test)
|
|
418
419
|
# check for problems in prolog
|
|
419
420
|
if test.rc == TEST_FAILED:
|
|
420
421
|
test = cert_common.test_epilog(test)
|
|
421
422
|
return test
|
|
422
423
|
|
|
423
|
-
|
|
424
|
+
# Adaptation of GW configuration for internal BRG test
|
|
425
|
+
if test.internal_brg:
|
|
426
|
+
test = cert_config.brg_configure(test, fields=[BRG_RX_CHANNEL], values=[ag.RX_CHANNEL_37], module=datapath_module, wait=True)[0]
|
|
427
|
+
if test.rc == TEST_FAILED and test.exit_on_param_failure:
|
|
428
|
+
return cert_common.test_epilog(test, revert_gws=True)
|
|
424
429
|
|
|
425
430
|
# create csv file for the test
|
|
426
431
|
in_pkts = create_csv_file_in(test)
|
|
@@ -434,7 +439,7 @@ def run(test):
|
|
|
434
439
|
|
|
435
440
|
for param in test.params:
|
|
436
441
|
phase_run_print(param.name)
|
|
437
|
-
test = EXT_SENSOR_TEST_MAP[param.value](test, param.name,
|
|
442
|
+
test = EXT_SENSOR_TEST_MAP[param.value](test, param.name, ext_sensors_module)
|
|
438
443
|
field_functionality_pass_fail_print(test, param.name)
|
|
439
444
|
test.set_phase_rc(param.name, test.rc)
|
|
440
445
|
test.add_phase_reason(param.name, test.reason)
|
|
@@ -447,4 +452,4 @@ def run(test):
|
|
|
447
452
|
if test.data == DATA_SIMULATION:
|
|
448
453
|
ble_sim_thread.stop()
|
|
449
454
|
|
|
450
|
-
return cert_common.test_epilog(test, revert_brgs=True, modules=[
|
|
455
|
+
return cert_common.test_epilog(test, revert_brgs=True, modules=[ext_sensors_module, datapath_module])
|
common/api_if/api_validation.py
CHANGED
|
@@ -25,12 +25,6 @@ def api_validation(test):
|
|
|
25
25
|
api_validation_phase.reason = "API validation is skipped for protobuf messages"
|
|
26
26
|
test.add_phase(api_validation_phase)
|
|
27
27
|
return test
|
|
28
|
-
elif not test.dut.gw_api_version:
|
|
29
|
-
utPrint("API validation is skipped because no API version was specified", "WARNING")
|
|
30
|
-
api_validation_phase.rc = TEST_FAILED
|
|
31
|
-
api_validation_phase.reason = "API validation is skipped because no API version was specified"
|
|
32
|
-
test.add_phase(api_validation_phase)
|
|
33
|
-
return test
|
|
34
28
|
else:
|
|
35
29
|
def validate_message(message: dict, msg_type=MESSAGE_TYPES.DATA.value) -> tuple[bool, str]:
|
|
36
30
|
json_path = pkg_resources.resource_filename(__name__, f"{test.dut.gw_api_version}/{msg_type}.json")
|