def test_compute_instance_id(self):
        initial = self.cache.compute_instance_id()
        later = [self.cache.compute_instance_id() for _ in range(10)]
        self.assertEqual(
            (later, self.counting_proxy.num_calls("compute_instance_id")),
            ([initial] * 10, 1))
Take an IP string/int and return an object of the correct type.
dataset/ETHPy150Open ClusterHQ/flocker/flocker/node/agents/test/test_blockdevice.py/ProcessLifetimeCacheTests.test_compute_instance_id--crossover with--dataset/ETHPy150Open Exa-Networks/exabgp/lib/exabgp/dep/ipaddress.py/ip_address