diff --git a/test/mocks.py b/test/mocks.py
index f644954f1764c5834983901568132f184cfcbd11..5790dbde6ae85ae0fe6311f432db786965a2475f 100644
--- a/test/mocks.py
+++ b/test/mocks.py
@@ -69,7 +69,7 @@ class MockInterface(Mock):
 
 class MockLogger(Mock):
 	def __init__(self):
-		Mock.__init__(self, {'write': None})
+		Mock.__init__(self, {'write': None, 'get_transports_type': {}})
 
 class MockContact(Mock):
 	def __nonzero__(self):
diff --git a/test/runtests.py b/test/runtests.py
new file mode 100755
index 0000000000000000000000000000000000000000..73ac4f4c840bdbe0d15ba6f9c6f0a6feaa7c7bbb
--- /dev/null
+++ b/test/runtests.py
@@ -0,0 +1,16 @@
+#!/usr/bin/env python
+
+import unittest
+
+# new test modules need to be added manually
+modules = ( 'test_caps',
+				'test_dispatcher_nb',
+				'test_misc_interface',
+				'test_roster',
+				'test_sessions',
+												)
+for mod in modules:
+	suite = unittest.defaultTestLoader.loadTestsFromName(mod)
+	unittest.TextTestRunner(verbosity=1).run(suite)
+
+# vim: se ts=3:
diff --git a/test/test_misc_interface.py b/test/test_misc_interface.py
index 860e89cd4fbfa35dda653194db6df27028bb65ac..5225e6ea043e6118faacf4dcee7f55b0be687abe 100644
--- a/test/test_misc_interface.py
+++ b/test/test_misc_interface.py
@@ -5,15 +5,10 @@ import testlib
 testlib.setup_env()
 
 from common import gajim
-from common import xmpp
-
-from common.caps import CapsCache
-
-from mock import Mock
-
 from gajim import Interface
 
-gajim.logger = Mock()
+from mocks import MockLogger
+gajim.logger = MockLogger()
 
 Interface()
 
diff --git a/test/test_roster.py b/test/test_roster.py
index 0ad390b10699e777ea39bfc5271968247f2d9c4a..6da8715f92fea0dfa0d1021addcc7a3022b5e94c 100755
--- a/test/test_roster.py
+++ b/test/test_roster.py
@@ -21,7 +21,7 @@ class TestRosterWindow(unittest.TestCase):
 	def setUp(self):
 		gajim.interface = MockInterface()
 		self.roster = roster_window.RosterWindow()
-		
+
 		# Please unuglify :-)
 		self.C_NAME = roster_window.C_NAME
 		self.C_TYPE = roster_window.C_TYPE
@@ -52,7 +52,7 @@ class TestRosterWindow(unittest.TestCase):
 			self.assertTrue(len(iters) == len(contact.get_shown_groups()),
 				msg='Contact is not in all his groups')
 
-			# check for each group tag	
+			# check for each group tag
 			for titerC in iters:
 				self.assertTrue(self.roster.model.iter_is_valid(titerC),
 					msg='Contact iter invalid')
@@ -67,7 +67,7 @@ class TestRosterWindow(unittest.TestCase):
 					self.assertEquals(account, c_model[self.C_ACCOUNT],
 						msg='Account missmatch')
 				# TODO: Is our parent correct? (group or big b)
-				
+
 	def assert_group_is_in_roster(self, group, account):
 		#TODO
 		pass
@@ -80,7 +80,7 @@ class TestRosterWindow(unittest.TestCase):
 		acc_model = self.roster.model[titerA]
 		self.assertEquals(acc_model[self.C_TYPE], 'account',
 			msg='No account found')
-		
+
 		if not self.roster.regroup:
 			self.assertEquals(acc_model[self.C_ACCOUNT], acc,
 				msg='Account not found')
@@ -88,7 +88,7 @@ class TestRosterWindow(unittest.TestCase):
 			self_jid = gajim.get_jid_from_account(acc)
 			self.assertEquals(acc_model[self.C_JID], self_jid,
 				msg='Account JID not found in account row')
-	
+
 	def assert_model_is_in_sync(self):
 		#TODO: check that iter_n_children returns the correct numbers
 		pass
@@ -97,18 +97,18 @@ class TestRosterWindow(unittest.TestCase):
 	def test_fill_contacts_and_groups_dicts(self):
 		for acc in contacts:
 			self.roster.fill_contacts_and_groups_dicts(contacts[acc], acc)
-			
+
 			for jid in contacts[acc]:
 				instances = gajim.contacts.get_contacts(acc, jid)
 
 				# Created a contact for each single jid?
 				self.assertTrue(len(instances) == 1)
-				
+
 				# Contacts kept their info
 				contact = instances[0]
 				self.assertEquals(contact.groups, contacts[acc][jid]['groups'],
 					msg='Group Missmatch')
-				
+
 				groups = contacts[acc][jid]['groups'] or ['General',]
 
 		# cleanup
@@ -123,9 +123,9 @@ class TestRosterWindow(unittest.TestCase):
 			self.roster.add_account(acc)
 			self.assert_account_is_in_roster(acc)
 
-			self.roster.add_account_contacts(acc)	
+			self.roster.add_account_contacts(acc)
 			self.assert_all_contacts_are_in_roster(acc)
-			
+
 		self.assert_model_is_in_sync()
 
 
@@ -166,6 +166,6 @@ class TestRosterWindowMetaContacts(TestRosterWindowRegrouped):
 
 
 if __name__ == '__main__':
-    unittest.main()
+	unittest.main()
 
 # vim: se ts=3:
diff --git a/test/testlib.py b/test/testlib.py
index 4beb43e1465a253ab93bdb4f2c4efe0c8b106be3..3682ba86a0beb4c3b7c775a21d46547d8ccef8d8 100644
--- a/test/testlib.py
+++ b/test/testlib.py
@@ -3,7 +3,8 @@ import os.path
 
 gajim_root = os.path.join(os.path.abspath(os.path.dirname(__file__)), '..')
 
-sys.path.append(gajim_root + '/src')
+# look for modules in the CWD, then gajim/src, then everywhere else
+sys.path.insert(1, gajim_root + '/src')
 
 # a temporary version of ~/.gajim for testing
 configdir = gajim_root + '/test/tmp'
@@ -34,4 +35,4 @@ def setup_env():
 	import gtkgui_helpers
 	gtkgui_helpers.GLADE_DIR = gajim_root + '/data/glade'
 
-# vim: se ts=3:
\ No newline at end of file
+# vim: se ts=3: