src/connectivity/wlan/drivers/third_party/broadcom/brcmfmac/sim/test/timeout_test.cc
// Verify association timeout is triggered.
Verify association timeout is triggered.
Verify association timeout is triggered .
TEST_F(TimeoutTest, AssocTimeout) {
  Init();
  simulation::FakeAp ap(env_.get(), kDefaultBssid, kDefaultSsid, kDefaultChannel);
  brcmf_simdev* sim = device_->GetSim();
  sim->sim_fw->err_inj_.AddErrInjCmd(BRCMF_C_SET_SSID, ZX_OK, client_ifc_.iface_id_);
  client_ifc_.AssociateWith(ap, zx::msec(10));
  env_->Run(kTestDuration);
  EXPECT_EQ(client_ifc_.stats_.assoc_attempts, 1U);
  const auto assoc_results = &client_ifc_.stats_.assoc_results;
  EXPECT_EQ(assoc_results->size(), 1U);
  EXPECT_EQ(assoc_results->front().result_code, WLAN_ASSOC_RESULT_REFUSED_REASON_UNSPECIFIED);
}
TEST_F ( TimeoutTest , AssocTimeout ) { Init ( ) ; simulation :: FakeAp ap ( env_ . get ( ) , kDefaultBssid , kDefaultSsid , kDefaultChannel ) ; brcmf_simdev * sim = device_ -> GetSim ( ) ; sim -> sim_fw -> err_inj_ . AddErrInjCmd ( BRCMF_C_SET_SSID , ZX_OK , client_ifc_ . iface_id_ ) ; client_ifc_ . AssociateWith ( ap , zx :: msec ( 10 ) ) ; env_ -> Run ( kTestDuration ) ; EXPECT_EQ ( client_ifc_ . stats_ . assoc_attempts , 1U ) ; const auto assoc_results = & client_ifc_ . stats_ . assoc_results ; EXPECT_EQ ( assoc_results -> size ( ) , 1U ) ; EXPECT_EQ ( assoc_results -> front ( ) . result_code , WLAN_ASSOC_RESULT_REFUSED_REASON_UNSPECIFIED ) ; }
Verify association timeout is triggered.
Verify association timeout is triggered .
// Ignore association req in sim-fw. // Receiving assoc_resp in SME with error status.