network_WiFi_RegDomain: test connection to hidden networks

Add testing of hidden networks to network_WiFi_RegDomain.
In particular, check that connecting to a hidden network
succeeds or fails just as connecting to a visible network
does.

The reason for testing hidden networks specifically is that
they exercise an additional code path in wireless core
regulatory code.

Namely: in a passive-scanning situation, we will initially
be unable to probe for a hidden network. But once we've seen
beacons from an AP (including beacons with the broadcast SSID,
from an AP running a hidden SSID), we remove the passive
scanning restriction. [1]

Note: given the above, we could limit the hidden SSID testing
to just those cases where a channel is configured for passive
scanning. For now, though, we optimize for similicity, rather
than run time.

While there: add a |description| argument to
WiFiTestContextManager.assert_connect_wifi(), so that we
can disambiguate similar connections in log files.

[1] https://wireless.wiki.kernel.org/en/developers/regulatory/processing_rules

BUG=chromium:485204
TEST=network_WiFi_RegDomain (on candy)

Change-Id: Ib56ca34b087aa91d23e4470cb63d68b897b559ab
Reviewed-on: https://chromium-review.googlesource.com/269972
Trybot-Ready: mukesh agrawal <quiche@chromium.org>
Tested-by: mukesh agrawal <quiche@chromium.org>
Reviewed-by: Zeping Qiu <zqiu@chromium.org>
Commit-Queue: mukesh agrawal <quiche@chromium.org>
2 files changed