def testWillSplitUrlIntoProperChunks(self): uri = "tcp://172.17.0.8:5000" expected = { 'protocol': 'tcp', 'host': '172.17.0.8', 'port': '5000' } self.assertDictEqual(split_uri(uri), expected)
def testWillRaiseValueErrorIfGivenUnprocessibleURI(self): uri = "thisis:/:some::bollocks" with self.assertRaises(ValueError): split_uri(uri)