[yast-commit] r58004 - in /branches/tmp/mvidner/core-dbus-values/dbus/namespace_service/testsuite: t3-unknown-method.py t5-params.py
Author: mvidner Date: Fri Jul 10 12:53:25 2009 New Revision: 58004 URL: http://svn.opensuse.org/viewcvs/yast?rev=58004&view=rev Log: Boolean tests Modified: branches/tmp/mvidner/core-dbus-values/dbus/namespace_service/testsuite/t3-unknown-method.py branches/tmp/mvidner/core-dbus-values/dbus/namespace_service/testsuite/t5-params.py Modified: branches/tmp/mvidner/core-dbus-values/dbus/namespace_service/testsuite/t3-unknown-method.py URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/mvidner/core-dbus-values/dbus/namespace_service/testsuite/t3-unknown-method.py?rev=58004&r1=58003&r2=58004&view=diff ============================================================================== --- branches/tmp/mvidner/core-dbus-values/dbus/namespace_service/testsuite/t3-unknown-method.py (original) +++ branches/tmp/mvidner/core-dbus-values/dbus/namespace_service/testsuite/t3-unknown-method.py Fri Jul 10 12:53:25 2009 @@ -17,6 +17,24 @@ def testUnknownMethodWithParams(self): self.assertRaisesDBus("UnknownMethod", self.T.NoSuchMethod, 42) + def testUnknownObject(self): + U_o = dbus.SessionBus().get_object('org.opensuse.YaST.modules', + '/borg/resistance/futile') + + def testUnknownModuleImplicit(self): + U_o = dbus.SessionBus().get_object('org.opensuse.YaST.modules', + '/org/opensuse/YaST/modules/UNKNOWN') + # ^ HUH, no exception? + U = dbus.Interface(U_o, 'org.opensuse.YaST.Values') + + def testUnknownModuleExplicit(self): + MM_o = dbus.SessionBus().get_object('org.opensuse.YaST.modules', + '/org/opensuse/YaST/modules') + MM = dbus.Interface(MM_o, 'org.opensuse.YaST.modules.ModuleManager') +# self.assertFalse(MM.Import("UNKNOWN")) +# TODO more sense to raise on error than return false +# self.assertRaisesDBus("", MM.Import, "UNKNOWN") + def testUnknownMethodBsvNoParams(self): self.assertRaisesDBus("UnknownMethod", self.YT.NoSuchMethod) Modified: branches/tmp/mvidner/core-dbus-values/dbus/namespace_service/testsuite/t5-params.py URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/mvidner/core-dbus-values/dbus/namespace_service/testsuite/t5-params.py?rev=58004&r1=58003&r2=58004&view=diff ============================================================================== --- branches/tmp/mvidner/core-dbus-values/dbus/namespace_service/testsuite/t5-params.py (original) +++ branches/tmp/mvidner/core-dbus-values/dbus/namespace_service/testsuite/t5-params.py Fri Jul 10 12:53:25 2009 @@ -40,6 +40,12 @@ self.T = dbus.Interface(T_o, 'org.opensuse.YaST.Values') # self.YT = dbus.Interface(T_o, 'org.opensuse.YaST.YCPValues') + def testBoolTrue(self): + self.assertEqual(self.T.ParamBoolean(True), True) + + def testBoolFalse(self): + self.assertEqual(self.T.ParamBoolean(False), False) + def testByte(self): self.assertEqual(self.T.ParamInteger(y), y42) -- To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org For additional commands, e-mail: yast-commit+help@opensuse.org
participants (1)
-
mvidner@svn.opensuse.org