Do not raise failure when a link property is not found.

get_link_value should not raise a failure when a link property is not
found. It should be the caller's responsibility for checking the return
value and act accordingly.

This eliminates the timing issue where the DUT might still be connected
to the undesired AP at the time wait_for_connection is called, and is
disconnected when the iw link command is issued to retrieve the frequency
information. Instead of failing right away because no frequency information
is found, recheck the frequency information when DUT is connected to the
desired AP.

BUG=chromium:418194
TEST=Run wifi_matfunc suite
DEPLOY=test_importer

Change-Id: I38865b79cd491d26f80915256f6065253e5f2876
Reviewed-on: https://chromium-review.googlesource.com/220561
Reviewed-by: Christopher Wiley <wiley@chromium.org>
Tested-by: Peter Qiu <zqiu@chromium.org>
Commit-Queue: Peter Qiu <zqiu@chromium.org>
2 files changed