From: Masashi Honma Date: Mon, 4 Feb 2019 00:56:53 +0000 (+0200) Subject: tests: Replace dict.has_key() with the in operator for python3 X-Git-Tag: hostap_2_8~441 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=b723b259264fc4329d41e3a10455066a030d66f5;p=thirdparty%2Fhostap.git tests: Replace dict.has_key() with the in operator for python3 Signed-off-by: Masashi Honma --- diff --git a/tests/hwsim/test_dbus.py b/tests/hwsim/test_dbus.py index 0e690fab3..1356fd00a 100644 --- a/tests/hwsim/test_dbus.py +++ b/tests/hwsim/test_dbus.py @@ -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()