flimflam: flimflam.py: allow SetDebugTags to function with shill Handle failures to SetDebugTags gracefully by trying to set the debug level which is all that can be done with shill. BUG=chromium-os:25566 TEST=run network_3GModemControl Change-Id: I699e49923f93eb7a3d41012d9c2104e3e4581bb8 Reviewed-on: https://gerrit.chromium.org/gerrit/14937 Commit-Ready: Jason Glasgow <jglasgow@chromium.org> Reviewed-by: Jason Glasgow <jglasgow@chromium.org> Tested-by: Jason Glasgow <jglasgow@chromium.org>
diff --git a/test/flimflam.py b/test/flimflam.py index bc11d6d..652c8ea 100644 --- a/test/flimflam.py +++ b/test/flimflam.py
@@ -329,7 +329,17 @@ return self.manager.ListDebugTags() def SetDebugTags(self, taglist): - self.manager.SetDebugTags(taglist) + try: + self.manager.SetDebugTags(taglist) + except dbus.exceptions.DBusException, error: + if error.get_dbus_name() not in [ + "org.freedesktop.DBus.Error.UnknownMethod" ]: + raise error + # Shill implements SetDebugLevel not SetDebugTags + self.SetDebugLevel(4) + + def SetDebugLevel(self, level): + self.manager.SetDebugLevel(level) def ConvertSSID(self, ssid_list): ssid = ""