tests: Use a helper function for DPP_QR_CODE commands

Signed-off-by: Jouni Malinen <j@w1.fi>
This commit is contained in:
Jouni Malinen 2019-03-09 16:50:48 +02:00
parent 7010f4bed5
commit 0422d06b54
4 changed files with 86 additions and 276 deletions

View file

@ -1334,3 +1334,9 @@ class WpaSupplicant:
break
else:
break
def dpp_qr_code(self, uri):
res = self.request("DPP_QR_CODE " + uri)
if "FAIL" in res:
raise Exception("Failed to parse QR Code URI")
return int(res)