

def test_url(self):
    schema = schemas.URLField.definition()
    definition = self.deserialize({
        'name': 'homepage',
        'type': 'url',
    })
    validator = schemas.URLField.validation(**definition)
    self.assertEquals('http://daybed.lolnet.org', validator.deserialize('http://daybed.lolnet.org'))
    self.assertRaises(colander.Invalid, validator.deserialize, 'http://lolnet/org')

dataset/ETHPy150Open spiral-project/daybed/daybed/tests/test_schemas_base.py BaseFieldsTests.test_url/VarMisuse@22/25 `schema`->`self`