'Accessing a field which does not exist returns a default.'

def testDefaults(self):

    tested = TestStruct()
    self.assertFalse(tested.HasField('foobar'))
    self.assertEqual(tested.foobar, 'string')
    self.assertFalse(tested.HasField('foobar'))
    self.assertFalse(tested.HasField('urn'))
    self.assertEqual(tested.urn, 'www.google.com')
    self.assertFalse(tested.HasField('urn'))
    self.assertFalse(tested.HasField('nested'))
    self.assertEqual(tested.nested.urn, 'www.google.com')
    self.assertTrue(tested.HasField('nested'))
    self.assertFalse(tested.nested.HasField('urn'))
