def test_object(self):

    class Dummy():
        pass
    dummy = Dummy
    dummy.value = uniform()
    dummy.foo = 'bar'
    dummy.ref = dummy
    spec = dummy
    parsed = ParsedSpec(spec)
    self.assertEqual(parsed.size(), 1)
    instance = parsed.instantiate([0])
    self.assertEqual(0, instance.value)
    self.assertEqual('bar', instance.foo)
    self.assertEqual(instance, instance.ref)
def test_object(self):

    class Dummy():
        pass
    dummy = Dummy
    dummy.value = uniform()
    dummy.foo = 'bar'
    dummy.ref = dummy
    spec = dummy
    parsed = ParsedSpec(spec)
    self.assertEqual(parsed.size(), 1)
    instance = parsed.instantiate([0])
    self.assertEqual(0, instance.value)
    self.assertEqual('bar', instance.foo)
    self.assertEqual(instance, instance.ref)