network_WiFi_TDLSPing: check if router supports TDLS

Jetstream APs (used for many Wifi autotests) don't support TLDS, but
we're trying to use one of the AP's radios as a TDLS client for the DUT
to ping. Obviously, this won't work on APs that don't support TDLS...

Check for this, so we don't waste time trying to debug the test when the
AP doesn't support it.

BUG=chromium:699735
TEST=`test_that ... network_WiFi_TDLSPing` on a DUT paired with a
     jetstream AP

Change-Id: I73f8eb42d64154c36594a8ecff35c882a9c8de2e
Signed-off-by: Brian Norris <briannorris@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/466091
Reviewed-by: Kirtika Ruchandani <kirtika@chromium.org>
diff --git a/server/site_tests/network_WiFi_TDLSPing/network_WiFi_TDLSPing.py b/server/site_tests/network_WiFi_TDLSPing/network_WiFi_TDLSPing.py
index 2e32383..e165977 100644
--- a/server/site_tests/network_WiFi_TDLSPing/network_WiFi_TDLSPing.py
+++ b/server/site_tests/network_WiFi_TDLSPing/network_WiFi_TDLSPing.py
@@ -103,6 +103,9 @@
         client_caps = self.context.client.capabilities
         if site_linux_system.LinuxSystem.CAPABILITY_TDLS not in client_caps:
             raise error.TestNAError('DUT is incapable of TDLS')
+        router_caps = self.context.router.capabilities
+        if site_linux_system.LinuxSystem.CAPABILITY_TDLS not in router_caps:
+            raise error.TestNAError('Router is incapable of TDLS')
 
         # Configure the AP.
         frequency = 2412