(Title was: \"How to write a unit test for a DBUS service written in Python?\")
I\'ve started to write a DBUS service using dbus-python, but I\'m having trouble writ
Simple solution: don't unit test through dbus.
Instead write your unit tests to call your methods directly. That fits in more naturally with the nature of unit tests.
You might also want some automated integration tests, that check running through dbus, but they don't need to be so complete, nor run in isolation. You can have setup that starts a real instance of your server, in a separate process.