@@ -246,22 +246,26 @@ static void bridge_entry_remove(uint16_t src, uint16_t dst, uint16_t net_idx1, u
246246static void tester_bridge_configure (void )
247247{
248248 uint8_t status ;
249- int err ;
250249
251250 LOG_INF ("Configuring bridge..." );
252251
252+ ASSERT_OK (
253+ bt_mesh_cfg_cli_net_transmit_set (0 , BRIDGE_ADDR , BT_MESH_TRANSMIT (2 , 20 ), & status ));
254+ if (status != BT_MESH_TRANSMIT (2 , 20 )) {
255+ FAIL ("Net transmit set failed (status %u)" , status );
256+ }
257+
253258 for (int i = 0 ; i < remote_nodes ; i ++ ) {
254- err = bt_mesh_cfg_cli_net_key_add (0 , BRIDGE_ADDR , i + 1 , subnet_keys [i ], & status );
255- if ( err || status ) {
256- FAIL ( "NetKey add failed (err %d, status %u)" , err , status );
257- return ;
259+ ASSERT_OK ( bt_mesh_cfg_cli_net_key_add (0 , BRIDGE_ADDR , i + 1 , subnet_keys [i ],
260+ & status ));
261+ if ( status ) {
262+ FAIL ( "NetKey add failed (status %u)" , status ) ;
258263 }
259264 }
260265
261266 ASSERT_OK (bt_mesh_brg_cfg_cli_set (0 , BRIDGE_ADDR , BT_MESH_BRG_CFG_ENABLED , & status ));
262267 if (status != BT_MESH_BRG_CFG_ENABLED ) {
263268 FAIL ("Subnet bridge set failed (status %u)" , status );
264- return ;
265269 }
266270
267271 /* Disable Relay feature to avoid interference in the test. */
@@ -271,7 +275,6 @@ static void tester_bridge_configure(void)
271275 BT_MESH_TRANSMIT (2 , 20 ), & status , & transmit ));
272276 if (status ) {
273277 FAIL ("Relay set failed (status %u)" , status );
274- return ;
275278 }
276279
277280 LOG_INF ("Bridge configured" );
0 commit comments