Some test scripts use "from gi.repository import GObject" whereas others
use "import gobject". gi.repository is not always available on embedded
systems, so convert all instances to this format:
try:
from gi.repository import GObject
except ImportError:
import gobject as GObject
Also, sort the imports in this order: system, dbus, gobject, bluezutils
This patch makes the python tests source-compatible with python 3, while
leaving the interpreter at python 2 for now.
The tradeoff is that this source is no longer compatible with python
versions < 2.6, and requires gobject-introspection for the glib-based
tests.