'Mock incoming subnets as autoaddressed.'

def _mock_slaac_for_subnet_ids(self, subnet_ids):

    def _get_subnet(context, subnet_id):
        if (subnet_id in subnet_ids):
            return {'ipv6_address_mode': constants.IPV6_SLAAC, 'ipv6_ra_mode': constants.IPV6_SLAAC}
        else:
            return {'ipv6_address_mode': None, 'ipv6_ra_mode': None}
    self.mixin._get_subnet = mock.Mock(side_effect=_get_subnet)
