[tracker] functional-tests: Fix regression introduced in commit 690eecb1



commit c7ebf4a6caad380e150899ac608f25e7cb1f432d
Author: Martin Kampas <martin kampas+gnomebugs ubedi net>
Date:   Mon Feb 24 16:00:26 2014 +0000

    functional-tests: Fix regression introduced in commit 690eecb1

 tests/functional-tests/common/utils/helpers.py |    9 ++++++---
 1 files changed, 6 insertions(+), 3 deletions(-)
---
diff --git a/tests/functional-tests/common/utils/helpers.py b/tests/functional-tests/common/utils/helpers.py
index 2f3f0a4..c5aa675 100644
--- a/tests/functional-tests/common/utils/helpers.py
+++ b/tests/functional-tests/common/utils/helpers.py
@@ -280,9 +280,12 @@ class StoreHelper (Helper):
         """
         try:
             result = self.resources.SparqlQuery (QUERY % (ontology_class))
-        except dbus.DBusException:
-            self.connect ()
-            result = self.resources.SparqlQuery (QUERY % (ontology_class))
+        except dbus.DBusException as (e):
+            if (e.get_dbus_name().startswith ("org.freedesktop.DBus")):
+                self.start ()
+                result = self.resources.SparqlQuery (QUERY % (ontology_class))
+            else:
+                raise (e)
             
         if (len (result) == 1):
             return int (result [0][0])


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]