Inline TestObject for net_obj_test.py as well
authordbs <dbs@9efc2488-bf62-4759-914b-345cdb29e865>
Mon, 9 May 2011 17:10:19 +0000 (17:10 +0000)
committerdbs <dbs@9efc2488-bf62-4759-914b-345cdb29e865>
Mon, 9 May 2011 17:10:19 +0000 (17:10 +0000)
Signed-off-by: Dan Scott <dan@coffeecode.net>
git-svn-id: svn://svn.open-ils.org/OpenSRF/trunk@2246 9efc2488-bf62-4759-914b-345cdb29e865

src/python/tests/net_obj_test.py

index 07e4fc8..000c6b0 100644 (file)
@@ -7,6 +7,17 @@ sys.path.insert(0, os.path.join(os.path.dirname(__file__), '..'))
 
 import osrf.json, osrf.net_obj, unittest
 
+class TestObject(object):
+    """Test object with basic JSON structures"""
+    def __init__(self):
+        self.int = 1
+        self.string = "two"
+        self.array = [1,2,3,4]
+        self.dict = {'foo': 'bar', 'key': 'value'}
+        self.true = True
+        self.false = False
+        self.null = None
+
 class CheckNetworkEncoder(unittest.TestCase):
     """Tests the NetworkEncoder JSON encoding extension"""