Merge pull request #10761 from jarvte/fix_nwinterface_statustest

Fix networkinterface non-blocking status test
pull/10776/head
Martin Kojtal 2019-06-09 18:21:15 +01:00 committed by GitHub
commit 3c2dd9ca89
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 0 deletions

View File

@ -131,6 +131,10 @@ void NETWORKINTERFACE_STATUS_NONBLOCK()
status = wait_status_callback();
TEST_ASSERT_EQUAL(NSAPI_STATUS_DISCONNECTED, status);
wait(1); // In cellular there might still come disconnected messages from the network which are sent to callback.
// This would cause this test to fail as next connect is already ongoing. So wait here a while until (hopefully)
// all messages also from the network have arrived.
}
net->attach(NULL);