'L{extractField} can extract fields from an object that\'s been saved and
loaded from JSON.'

def test_extractingFieldsPostLoad(self):

    class Obj(object, ):
        def __init__(self):
            self.value = 345
    inputEvent = dict(log_format='{object.value}', object=Obj())
    loadedEvent = eventFromJSON(self.savedEventJSON(inputEvent))
    self.assertEqual(extractField('object.value', loadedEvent), 345)
    self.assertRaises(KeyError, extractField, 'object', loadedEvent)
    self.assertRaises(KeyError, extractField, 'object', inputEvent)
