diff options
author | mike <michael.jmontcalm@gmail.com> | 2009-04-06 02:38:10 (GMT) |
---|---|---|
committer | mike <michael.jmontcalm@gmail.com> | 2009-04-16 00:52:40 (GMT) |
commit | 0cad6dc96afc2ebd4d03beb14ed01bc155dfa322 (patch) | |
tree | d86b51b031aa5da74d3d7935020e468fa6ab4919 /src/sugar/tutorius/tests/actiontests.py | |
parent | aefa4024904ec92034d108d94768a388e8f1a9f6 (diff) |
LP 348570 Core : Extending actions with the new properties, adding min /
max size to arrays
Diffstat (limited to 'src/sugar/tutorius/tests/actiontests.py')
-rw-r--r-- | src/sugar/tutorius/tests/actiontests.py | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/src/sugar/tutorius/tests/actiontests.py b/src/sugar/tutorius/tests/actiontests.py index d1de5fd..cfb6114 100644 --- a/src/sugar/tutorius/tests/actiontests.py +++ b/src/sugar/tutorius/tests/actiontests.py @@ -29,15 +29,7 @@ from sugar.tutorius.services import ObjectStore class PropertyAction(Action): def __init__(self, na): - self._a = na - - def set_a(self, na): - self._a = na - - def get_a(self): - return self._a - - a = property(fget=get_a, fset=set_a) + self.a = TIntProperty(na) def has_function(obj, function_name): """ @@ -54,6 +46,7 @@ class PropsTest(unittest.TestCase): assert prop.get_properties() == ['a'], "Action does not contain property 'a'" +class OnceWrapperTest(unittest.TestCase): def validate_wrapper(self, wrapper_instance): """ Ensures that a given instance of a wrapper implements the Action @@ -67,7 +60,7 @@ class PropsTest(unittest.TestCase): assert has_function(wrapper_instance, "get_properties"),\ "The wrapper does not have the 'get_properties' function." - + def test_once_wrapper_interface(self): """ Tests that the interface of the OnceWrapper actually conforms to the of |