]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
tests: Replace dict.has_key() with the in operator for python3
authorMasashi Honma <masashi.honma@gmail.com>
Mon, 4 Feb 2019 00:56:53 +0000 (02:56 +0200)
committerJouni Malinen <j@w1.fi>
Mon, 4 Feb 2019 10:26:35 +0000 (12:26 +0200)
Signed-off-by: Masashi Honma <masashi.honma@gmail.com>
tests/hwsim/test_dbus.py

index 0e690fab32df8c0e1d3680ade49b2146820f1df1..1356fd00a8a953d1cc7a58044189f859f9da5381 100644 (file)
@@ -475,7 +475,7 @@ def _test_dbus_get_set_wps(dev, apdev):
 
         def propertiesChanged(self, properties):
             logger.debug("PropertiesChanged: " + str(properties))
-            if properties.has_key("ProcessCredentials"):
+            if "ProcessCredentials" in properties:
                 self.signal_received_deprecated = True
                 if self.sets_done and self.signal_received:
                     self.loop.quit()
@@ -485,7 +485,7 @@ def _test_dbus_get_set_wps(dev, apdev):
             logger.debug("propertiesChanged2: interface_name=%s changed_properties=%s invalidated_properties=%s" % (interface_name, str(changed_properties), str(invalidated_properties)))
             if interface_name != WPAS_DBUS_IFACE_WPS:
                 return
-            if changed_properties.has_key("ProcessCredentials"):
+            if "ProcessCredentials" in changed_properties:
                 self.signal_received = True
                 if self.sets_done and self.signal_received_deprecated:
                     self.loop.quit()